|
| 1 | +<?php |
| 2 | +namespace FedEx\InFlightShipmentService\ComplexType; |
| 3 | + |
| 4 | +use FedEx\AbstractComplexType; |
| 5 | + |
| 6 | +/** |
| 7 | + * Descriptive data for a physical location. May be used as an actual physical address (place to which one could go), or as a container of "address parts" which should be handled as a unit (such as a city-state-ZIP combination within the US). |
| 8 | + * |
| 9 | + * @author Jeremy Dunn <[email protected]> |
| 10 | + * @package PHP FedEx API wrapper |
| 11 | + * @subpackage In Flight Shipment Service |
| 12 | + * |
| 13 | + * @property string[] $StreetLines |
| 14 | + * @property string $City |
| 15 | + * @property string $StateOrProvinceCode |
| 16 | + * @property string $PostalCode |
| 17 | + * @property string $UrbanizationCode |
| 18 | + * @property string $CountryCode |
| 19 | + * @property string $CountryName |
| 20 | + * @property boolean $Residential |
| 21 | +
|
| 22 | + */ |
| 23 | +class Address extends AbstractComplexType |
| 24 | +{ |
| 25 | + /** |
| 26 | + * Name of this complex type |
| 27 | + * |
| 28 | + * @var string |
| 29 | + */ |
| 30 | + protected $name = 'Address'; |
| 31 | + |
| 32 | + /** |
| 33 | + * Combination of number, street name, etc. At least one line is required for a valid physical address; empty lines should not be included. |
| 34 | + * |
| 35 | + * @param string $streetLines |
| 36 | + * @return $this |
| 37 | + */ |
| 38 | + public function setStreetLines($streetLines) |
| 39 | + { |
| 40 | + $this->values['StreetLines'] = $streetLines; |
| 41 | + return $this; |
| 42 | + } |
| 43 | + |
| 44 | + /** |
| 45 | + * Name of city, town, etc. |
| 46 | + * |
| 47 | + * @param string $city |
| 48 | + * @return $this |
| 49 | + */ |
| 50 | + public function setCity($city) |
| 51 | + { |
| 52 | + $this->values['City'] = $city; |
| 53 | + return $this; |
| 54 | + } |
| 55 | + |
| 56 | + /** |
| 57 | + * Identifying abbreviation for US state, Canada province, etc. Format and presence of this field will vary, depending on country. |
| 58 | + * |
| 59 | + * @param string $stateOrProvinceCode |
| 60 | + * @return $this |
| 61 | + */ |
| 62 | + public function setStateOrProvinceCode($stateOrProvinceCode) |
| 63 | + { |
| 64 | + $this->values['StateOrProvinceCode'] = $stateOrProvinceCode; |
| 65 | + return $this; |
| 66 | + } |
| 67 | + |
| 68 | + /** |
| 69 | + * Identification of a region (usually small) for mail/package delivery. Format and presence of this field will vary, depending on country. |
| 70 | + * |
| 71 | + * @param string $postalCode |
| 72 | + * @return $this |
| 73 | + */ |
| 74 | + public function setPostalCode($postalCode) |
| 75 | + { |
| 76 | + $this->values['PostalCode'] = $postalCode; |
| 77 | + return $this; |
| 78 | + } |
| 79 | + |
| 80 | + /** |
| 81 | + * Relevant only to addresses in Puerto Rico. |
| 82 | + * |
| 83 | + * @param string $urbanizationCode |
| 84 | + * @return $this |
| 85 | + */ |
| 86 | + public function setUrbanizationCode($urbanizationCode) |
| 87 | + { |
| 88 | + $this->values['UrbanizationCode'] = $urbanizationCode; |
| 89 | + return $this; |
| 90 | + } |
| 91 | + |
| 92 | + /** |
| 93 | + * The two-letter code used to identify a country. |
| 94 | + * |
| 95 | + * @param string $countryCode |
| 96 | + * @return $this |
| 97 | + */ |
| 98 | + public function setCountryCode($countryCode) |
| 99 | + { |
| 100 | + $this->values['CountryCode'] = $countryCode; |
| 101 | + return $this; |
| 102 | + } |
| 103 | + |
| 104 | + /** |
| 105 | + * The fully spelt out name of a country. |
| 106 | + * |
| 107 | + * @param string $countryName |
| 108 | + * @return $this |
| 109 | + */ |
| 110 | + public function setCountryName($countryName) |
| 111 | + { |
| 112 | + $this->values['CountryName'] = $countryName; |
| 113 | + return $this; |
| 114 | + } |
| 115 | + |
| 116 | + /** |
| 117 | + * Indicates whether this address residential (as opposed to commercial). |
| 118 | + * |
| 119 | + * @param boolean $residential |
| 120 | + * @return $this |
| 121 | + */ |
| 122 | + public function setResidential($residential) |
| 123 | + { |
| 124 | + $this->values['Residential'] = $residential; |
| 125 | + return $this; |
| 126 | + } |
| 127 | +} |
0 commit comments