1 | <?php |
||
14 | final class City |
||
15 | { |
||
16 | /** |
||
17 | * @var int |
||
18 | */ |
||
19 | private $id; |
||
20 | |||
21 | /** |
||
22 | * @var string |
||
23 | */ |
||
24 | private $name; |
||
25 | |||
26 | /** |
||
27 | * @var string|null |
||
28 | */ |
||
29 | private $state; |
||
30 | |||
31 | /** |
||
32 | * @var string|null |
||
33 | */ |
||
34 | private $stateCode; |
||
35 | |||
36 | /** |
||
37 | * @var Country|null |
||
38 | */ |
||
39 | private $country; |
||
40 | |||
41 | /** |
||
42 | * @var Geo|null |
||
43 | */ |
||
44 | private $geo; |
||
45 | |||
46 | public function __construct( |
||
61 | |||
62 | public function getId(): int |
||
66 | |||
67 | public function getName(): string |
||
71 | |||
72 | public function getState(): ?string |
||
76 | |||
77 | public function getStateCode(): ?string |
||
81 | |||
82 | /** |
||
83 | * @deprecated use getCountry instead |
||
84 | */ |
||
85 | public function getCounty(): ?Country |
||
89 | |||
90 | public function getCountry(): ?Country |
||
94 | |||
95 | public function getGeo(): ?Geo |
||
99 | |||
100 | /** |
||
101 | * @return City |
||
102 | */ |
||
103 | public static function fromApi(array $data): self |
||
125 | } |
||
126 |