| 1 | <?php |
||
| 19 | class A implements RdataInterface |
||
| 20 | { |
||
| 21 | use RdataTrait; |
||
| 22 | |||
| 23 | const TYPE = 'A'; |
||
| 24 | const TYPE_CODE = 1; |
||
| 25 | |||
| 26 | /** |
||
| 27 | * @var string |
||
| 28 | */ |
||
| 29 | protected $address; |
||
| 30 | |||
| 31 | /** |
||
| 32 | * @param string $address |
||
| 33 | */ |
||
| 34 | 27 | public function setAddress(string $address): void |
|
| 38 | |||
| 39 | /** |
||
| 40 | * @return string |
||
| 41 | */ |
||
| 42 | 9 | public function getAddress(): ?string |
|
| 46 | |||
| 47 | /** |
||
| 48 | * {@inheritdoc} |
||
| 49 | */ |
||
| 50 | 7 | public function toText(): string |
|
| 54 | |||
| 55 | /** |
||
| 56 | * {@inheritdoc} |
||
| 57 | * |
||
| 58 | * @throws \InvalidArgumentException |
||
| 59 | */ |
||
| 60 | 2 | public function toWire(): string |
|
| 68 | |||
| 69 | /** |
||
| 70 | * {@inheritdoc} |
||
| 71 | */ |
||
| 72 | 9 | public static function fromText(string $text): RdataInterface |
|
| 79 | |||
| 80 | /** |
||
| 81 | * {@inheritdoc} |
||
| 82 | * |
||
| 83 | * @throws DecodeException |
||
| 84 | */ |
||
| 85 | 5 | public static function fromWire(string $rdata): RdataInterface |
|
| 96 | } |
||
| 97 |