-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
26 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,14 +4,21 @@ | |
|
||
namespace Rentpost\ForteApi\Model; | ||
|
||
use Rentpost\ForteApi\Model as Model; | ||
use Rentpost\ForteApi\Attribute as Attribute; | ||
use Symfony\Component\Validator\Constraints as Assert; | ||
|
||
/** | ||
* PhysicalAddress Model | ||
* | ||
* @author Sam Anthony <[email protected]> | ||
* @author Jacob Thomason <[email protected]> | ||
*/ | ||
class PhysicalAddress extends AbstractModel | ||
{ | ||
|
||
/** | ||
* @var string | ||
* @Assert\NotBlank() | ||
* @Assert\Length(max=35) | ||
*/ | ||
protected $streetLine1; | ||
|
@@ -23,27 +30,33 @@ class PhysicalAddress extends AbstractModel | |
protected $streetLine2; | ||
|
||
/** | ||
* town/village/city | ||
* Town/village/city | ||
* | ||
* @var string | ||
* @Assert\NotBlank() | ||
* @Assert\Length(max=25) | ||
*/ | ||
protected $locality; | ||
|
||
/** | ||
* state or province | ||
* State or province | ||
* | ||
* @var string | ||
* @Assert\NotBlank() | ||
* @Assert\Length(max=2) | ||
*/ | ||
protected $region; | ||
|
||
/** | ||
* @var Attribute\PostalCode | ||
* @Assert\NotBlank() | ||
* @Assert\Length(max=15) | ||
*/ | ||
protected $postalCode; | ||
|
||
|
||
/** | ||
* @return string | ||
* Gets the street address | ||
*/ | ||
public function getStreetLine1(): string | ||
{ | ||
|
@@ -52,9 +65,7 @@ public function getStreetLine1(): string | |
|
||
|
||
/** | ||
* @param string $streetLine1 | ||
* | ||
* @return self | ||
* Sets street address | ||
*/ | ||
public function setStreetLine1(string $streetLine1): self | ||
{ | ||
|
@@ -65,7 +76,7 @@ public function setStreetLine1(string $streetLine1): self | |
|
||
|
||
/** | ||
* @return string|null | ||
* Get apt, suite, etc. | ||
*/ | ||
public function getStreetLine2(): ?string | ||
{ | ||
|
@@ -74,9 +85,7 @@ public function getStreetLine2(): ?string | |
|
||
|
||
/** | ||
* @param string|null $streetLine2 | ||
* | ||
* @return self | ||
* Set apt, suite, etc. | ||
*/ | ||
public function setStreetLine2(?string $streetLine2): self | ||
{ | ||
|
@@ -87,7 +96,7 @@ public function setStreetLine2(?string $streetLine2): self | |
|
||
|
||
/** | ||
* @return string | ||
* Gets the locatlity | ||
*/ | ||
public function getLocality(): string | ||
{ | ||
|
@@ -96,9 +105,7 @@ public function getLocality(): string | |
|
||
|
||
/** | ||
* @param string $locality | ||
* | ||
* @return self | ||
* Sets the locality | ||
*/ | ||
public function setLocality(string $locality): self | ||
{ | ||
|
@@ -109,7 +116,7 @@ public function setLocality(string $locality): self | |
|
||
|
||
/** | ||
* @return string | ||
* Gets the region | ||
*/ | ||
public function getRegion(): string | ||
{ | ||
|
@@ -118,9 +125,7 @@ public function getRegion(): string | |
|
||
|
||
/** | ||
* @param string $region | ||
* | ||
* @return self | ||
* Sets the region | ||
*/ | ||
public function setRegion(string $region): self | ||
{ | ||
|
@@ -131,7 +136,7 @@ public function setRegion(string $region): self | |
|
||
|
||
/** | ||
* @return Attribute\PostalCode | ||
* Gets the postal code | ||
*/ | ||
public function getPostalCode(): Attribute\PostalCode | ||
{ | ||
|
@@ -140,18 +145,12 @@ public function getPostalCode(): Attribute\PostalCode | |
|
||
|
||
/** | ||
* @param Attribute\PostalCode $postalCode | ||
* | ||
* @return self | ||
* Sets the postal code | ||
*/ | ||
public function setPostalCode(Attribute\PostalCode $postalCode): self | ||
{ | ||
$this->postalCode = $postalCode; | ||
|
||
return $this; | ||
} | ||
|
||
|
||
|
||
|
||
} |