<?php
use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for Stradario_Model StructType
 * Meta information extracted from the WSDL
 * - nillable: true
 * - type: tns:Stradario_Model
 * @subpackage Structs
 */
class Stradario_Model extends AbstractStructBase
{
    /**
     * The CAP
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $CAP;
    /**
     * The Comune
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var Comune_Model
     */
    public $Comune;
    /**
     * The Descrizione
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Descrizione;
    /**
     * The Identifier
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var Stradario_Identifier_Model
     */
    public $Identifier;
    /**
     * The Localita
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Localita;
    /**
     * The Provincia
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var Provincia_Model
     */
    public $Provincia;
    /**
     * The Specifica
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Specifica;
    /**
     * Constructor method for Stradario_Model
     * @uses Stradario_Model::setCAP()
     * @uses Stradario_Model::setComune()
     * @uses Stradario_Model::setDescrizione()
     * @uses Stradario_Model::setIdentifier()
     * @uses Stradario_Model::setLocalita()
     * @uses Stradario_Model::setProvincia()
     * @uses Stradario_Model::setSpecifica()
     * @param string $cAP
     * @param Comune_Model $comune
     * @param string $descrizione
     * @param Stradario_Identifier_Model $identifier
     * @param string $localita
     * @param Provincia_Model $provincia
     * @param string $specifica
     */
    public function __construct($cAP = null, Comune_Model $comune = null, $descrizione = null, Stradario_Identifier_Model $identifier = null, $localita = null, Provincia_Model $provincia = null, $specifica = null)
    {
        $this
            ->setCAP($cAP)
            ->setComune($comune)
            ->setDescrizione($descrizione)
            ->setIdentifier($identifier)
            ->setLocalita($localita)
            ->setProvincia($provincia)
            ->setSpecifica($specifica);
    }
    /**
     * Get CAP value
     * An additional test has been added (isset) before returning the property value as
     * this property may have been unset before, due to the fact that this property is
     * removable from the request (nillable=true+minOccurs=0)
     * @return string|null
     */
    public function getCAP()
    {
        return isset($this->CAP) ? $this->CAP : null;
    }
    /**
     * Set CAP value
     * This property is removable from request (nillable=true+minOccurs=0), therefore
     * if the value assigned to this property is null, it is removed from this object
     * @param string $cAP
     * @return Stradario_Model
     */
    public function setCAP($cAP = null)
    {
        // validation for constraint: string
        if (!is_null($cAP) && !is_string($cAP)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($cAP, true), gettype($cAP)), __LINE__);
        }
        if (is_null($cAP) || (is_array($cAP) && empty($cAP))) {
            unset($this->CAP);
        } else {
            $this->CAP = $cAP;
        }
        return $this;
    }
    /**
     * Get Comune value
     * An additional test has been added (isset) before returning the property value as
     * this property may have been unset before, due to the fact that this property is
     * removable from the request (nillable=true+minOccurs=0)
     * @return Comune_Model|null
     */
    public function getComune()
    {
        return isset($this->Comune) ? $this->Comune : null;
    }
    /**
     * Set Comune value
     * This property is removable from request (nillable=true+minOccurs=0), therefore
     * if the value assigned to this property is null, it is removed from this object
     * @param Comune_Model $comune
     * @return Stradario_Model
     */
    public function setComune(Comune_Model $comune = null)
    {
        if (is_null($comune) || (is_array($comune) && empty($comune))) {
            unset($this->Comune);
        } else {
            $this->Comune = $comune;
        }
        return $this;
    }
    /**
     * Get Descrizione value
     * An additional test has been added (isset) before returning the property value as
     * this property may have been unset before, due to the fact that this property is
     * removable from the request (nillable=true+minOccurs=0)
     * @return string|null
     */
    public function getDescrizione()
    {
        return isset($this->Descrizione) ? $this->Descrizione : null;
    }
    /**
     * Set Descrizione value
     * This property is removable from request (nillable=true+minOccurs=0), therefore
     * if the value assigned to this property is null, it is removed from this object
     * @param string $descrizione
     * @return Stradario_Model
     */
    public function setDescrizione($descrizione = null)
    {
        // validation for constraint: string
        if (!is_null($descrizione) && !is_string($descrizione)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($descrizione, true), gettype($descrizione)), __LINE__);
        }
        if (is_null($descrizione) || (is_array($descrizione) && empty($descrizione))) {
            unset($this->Descrizione);
        } else {
            $this->Descrizione = $descrizione;
        }
        return $this;
    }
    /**
     * Get Identifier value
     * An additional test has been added (isset) before returning the property value as
     * this property may have been unset before, due to the fact that this property is
     * removable from the request (nillable=true+minOccurs=0)
     * @return Stradario_Identifier_Model|null
     */
    public function getIdentifier()
    {
        return isset($this->Identifier) ? $this->Identifier : null;
    }
    /**
     * Set Identifier value
     * This property is removable from request (nillable=true+minOccurs=0), therefore
     * if the value assigned to this property is null, it is removed from this object
     * @param Stradario_Identifier_Model $identifier
     * @return Stradario_Model
     */
    public function setIdentifier(Stradario_Identifier_Model $identifier = null)
    {
        if (is_null($identifier) || (is_array($identifier) && empty($identifier))) {
            unset($this->Identifier);
        } else {
            $this->Identifier = $identifier;
        }
        return $this;
    }
    /**
     * Get Localita value
     * An additional test has been added (isset) before returning the property value as
     * this property may have been unset before, due to the fact that this property is
     * removable from the request (nillable=true+minOccurs=0)
     * @return string|null
     */
    public function getLocalita()
    {
        return isset($this->Localita) ? $this->Localita : null;
    }
    /**
     * Set Localita value
     * This property is removable from request (nillable=true+minOccurs=0), therefore
     * if the value assigned to this property is null, it is removed from this object
     * @param string $localita
     * @return Stradario_Model
     */
    public function setLocalita($localita = null)
    {
        // validation for constraint: string
        if (!is_null($localita) && !is_string($localita)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($localita, true), gettype($localita)), __LINE__);
        }
        if (is_null($localita) || (is_array($localita) && empty($localita))) {
            unset($this->Localita);
        } else {
            $this->Localita = $localita;
        }
        return $this;
    }
    /**
     * Get Provincia value
     * An additional test has been added (isset) before returning the property value as
     * this property may have been unset before, due to the fact that this property is
     * removable from the request (nillable=true+minOccurs=0)
     * @return Provincia_Model|null
     */
    public function getProvincia()
    {
        return isset($this->Provincia) ? $this->Provincia : null;
    }
    /**
     * Set Provincia value
     * This property is removable from request (nillable=true+minOccurs=0), therefore
     * if the value assigned to this property is null, it is removed from this object
     * @param Provincia_Model $provincia
     * @return Stradario_Model
     */
    public function setProvincia(Provincia_Model $provincia = null)
    {
        if (is_null($provincia) || (is_array($provincia) && empty($provincia))) {
            unset($this->Provincia);
        } else {
            $this->Provincia = $provincia;
        }
        return $this;
    }
    /**
     * Get Specifica value
     * An additional test has been added (isset) before returning the property value as
     * this property may have been unset before, due to the fact that this property is
     * removable from the request (nillable=true+minOccurs=0)
     * @return string|null
     */
    public function getSpecifica()
    {
        return isset($this->Specifica) ? $this->Specifica : null;
    }
    /**
     * Set Specifica value
     * This property is removable from request (nillable=true+minOccurs=0), therefore
     * if the value assigned to this property is null, it is removed from this object
     * @param string $specifica
     * @return Stradario_Model
     */
    public function setSpecifica($specifica = null)
    {
        // validation for constraint: string
        if (!is_null($specifica) && !is_string($specifica)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($specifica, true), gettype($specifica)), __LINE__);
        }
        if (is_null($specifica) || (is_array($specifica) && empty($specifica))) {
            unset($this->Specifica);
        } else {
            $this->Specifica = $specifica;
        }
        return $this;
    }
}
