| Total Complexity | 5 |
| Total Lines | 58 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 11 | abstract class AbstractAddress implements QrCodeableInterface, SelfValidatableInterface |
||
| 12 | { |
||
| 13 | use SelfValidatableTrait; |
||
| 14 | |||
| 15 | /** |
||
| 16 | * Name or company |
||
| 17 | * |
||
| 18 | * @var string |
||
| 19 | */ |
||
| 20 | private $name; |
||
| 21 | |||
| 22 | /** |
||
| 23 | * Country (ISO 3166-1 alpha-2) |
||
| 24 | * |
||
| 25 | * @var string |
||
| 26 | */ |
||
| 27 | private $country; |
||
| 28 | |||
| 29 | abstract public function getFullAddress() : string; |
||
| 30 | |||
| 31 | abstract public function getQrCodeData() : array; |
||
| 32 | |||
| 33 | public function getName(): ?string |
||
| 34 | { |
||
| 35 | return $this->name; |
||
| 36 | } |
||
| 37 | |||
| 38 | public function setName(string $name) : self |
||
| 39 | { |
||
| 40 | $this->name = $name; |
||
| 41 | |||
| 42 | return $this; |
||
| 43 | } |
||
| 44 | |||
| 45 | public function getCountry(): ?string |
||
| 46 | { |
||
| 47 | return $this->country; |
||
| 48 | } |
||
| 49 | |||
| 50 | public function setCountry(string $country) : self |
||
| 55 | } |
||
| 56 | |||
| 57 | public static function loadValidatorMetadata(ClassMetadataInterface $metadata) : void |
||
| 58 | { |
||
| 71 | } |