/
dimamir
/
Wsdl_PackageGenerator
Обзор
Документация
Войти
/
dimamir
/
Wsdl_PackageGenerator
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
develop
src/Model/Wsdl.php
49 строк
1 KB
Mikaël DELSOL
issue #124 - implement PHP >= 7.4 tasks
01 мар 2021, 22:36
01 мар 2021, 22:36
8447c9b
Код
Авторство
О чём код?
<?php declare(strict_types=1); namespace WsdlToPhp\PackageGenerator\Model; use WsdlToPhp\PackageGenerator\Container\Model\Schema as SchemaContainer; use WsdlToPhp\PackageGenerator\Generator\Generator; use WsdlToPhp\WsdlHandler\Wsdl as WsdlDocument; final class Wsdl extends AbstractDocument { private SchemaContainer $schemas; public function __construct(Generator $generator, string $name, string $content) { parent::__construct($generator, $name, $content); $this->schemas = new SchemaContainer($generator); } public function getContent(): WsdlDocument { return parent::getContent(); } public function addSchema(Schema $schema): self { $this->getContent()->addExternalSchema($schema->getContent()); $this->schemas->add($schema); return $this; } public function hasSchema(string $schemaLocation): bool { return $this->schemas->getSchemaByName($schemaLocation) instanceof Schema; } public function getSchemas(): SchemaContainer { return $this->schemas; } protected function contentClass(): string { return WsdlDocument::class; } }