| 1 | <?php |
||
| 21 | abstract class AbstractTypeDefinition extends AbstractDefinition implements TypeDefinition |
||
| 22 | { |
||
| 23 | use HasName; |
||
| 24 | use HasDirectives; |
||
| 25 | use HasDeprecation; |
||
| 26 | use HasInheritance; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * @var string|null |
||
| 30 | */ |
||
| 31 | protected $description; |
||
| 32 | |||
| 33 | /** |
||
| 34 | * AbstractTypeDefinition constructor. |
||
| 35 | * @param Document|\Railt\Reflection\Contracts\Document $document |
||
| 36 | * @param string $name |
||
| 37 | */ |
||
| 38 | 9 | public function __construct(Document $document, string $name) |
|
| 43 | |||
| 44 | /** |
||
| 45 | * @return string |
||
| 46 | */ |
||
| 47 | public function getDescription(): string |
||
| 51 | |||
| 52 | /** |
||
| 53 | * @param null|string $description |
||
| 54 | * @return TypeDefinition|$this |
||
| 55 | */ |
||
| 56 | 9 | public function withDescription(?string $description): TypeDefinition |
|
| 62 | |||
| 63 | /** |
||
| 64 | * @return bool |
||
| 65 | */ |
||
| 66 | public function isBuiltin(): bool |
||
| 70 | |||
| 71 | /** |
||
| 72 | * @return string |
||
| 73 | */ |
||
| 74 | public function __toString(): string |
||
| 78 | } |
||
| 79 |