<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for PersonAddress StructType
 * @subpackage Structs
 */
class PersonAddress extends AbstractStructBase
{
    /**
     * The HouseNr
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var string
     */
    public $HouseNr;
    /**
     * The Street
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var string
     */
    public $Street;
    /**
     * The ZipCode
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var string
     */
    public $ZipCode;
    /**
     * The CountryCode
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var string
     */
    public $CountryCode;
    /**
     * Constructor method for PersonAddress
     * @uses PersonAddress::setHouseNr()
     * @uses PersonAddress::setStreet()
     * @uses PersonAddress::setZipCode()
     * @uses PersonAddress::setCountryCode()
     * @param string $houseNr
     * @param string $street
     * @param string $zipCode
     * @param string $countryCode
     */
    public function __construct($houseNr = null, $street = null, $zipCode = null, $countryCode = null)
    {
        $this
            ->setHouseNr($houseNr)
            ->setStreet($street)
            ->setZipCode($zipCode)
            ->setCountryCode($countryCode);
    }
    /**
     * Get HouseNr value
     * @return string|null
     */
    public function getHouseNr()
    {
        return $this->HouseNr;
    }
    /**
     * Set HouseNr value
     * @param string $houseNr
     * @return \StructType\PersonAddress
     */
    public function setHouseNr($houseNr = null)
    {
        // validation for constraint: string
        if (!is_null($houseNr) && !is_string($houseNr)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($houseNr, true), gettype($houseNr)), __LINE__);
        }
        $this->HouseNr = $houseNr;
        return $this;
    }
    /**
     * Get Street value
     * @return string|null
     */
    public function getStreet()
    {
        return $this->Street;
    }
    /**
     * Set Street value
     * @param string $street
     * @return \StructType\PersonAddress
     */
    public function setStreet($street = null)
    {
        // validation for constraint: string
        if (!is_null($street) && !is_string($street)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($street, true), gettype($street)), __LINE__);
        }
        $this->Street = $street;
        return $this;
    }
    /**
     * Get ZipCode value
     * @return string|null
     */
    public function getZipCode()
    {
        return $this->ZipCode;
    }
    /**
     * Set ZipCode value
     * @param string $zipCode
     * @return \StructType\PersonAddress
     */
    public function setZipCode($zipCode = null)
    {
        // validation for constraint: string
        if (!is_null($zipCode) && !is_string($zipCode)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($zipCode, true), gettype($zipCode)), __LINE__);
        }
        $this->ZipCode = $zipCode;
        return $this;
    }
    /**
     * Get CountryCode value
     * @return string|null
     */
    public function getCountryCode()
    {
        return $this->CountryCode;
    }
    /**
     * Set CountryCode value
     * @param string $countryCode
     * @return \StructType\PersonAddress
     */
    public function setCountryCode($countryCode = null)
    {
        // validation for constraint: string
        if (!is_null($countryCode) && !is_string($countryCode)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($countryCode, true), gettype($countryCode)), __LINE__);
        }
        $this->CountryCode = $countryCode;
        return $this;
    }
}
