<?php
use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for NotificationReceiver StructType
 * @subpackage Structs
 */
class NotificationReceiver extends AbstractStructBase
{
    /**
     * The id
     * Meta informations extracted from the WSDL
     * - nillable: true
     * @var int
     */
    public $id;
    /**
     * The idNotification
     * Meta informations extracted from the WSDL
     * - nillable: true
     * @var int
     */
    public $idNotification;
    /**
     * The receiverId
     * Meta informations extracted from the WSDL
     * - nillable: true
     * @var string
     */
    public $receiverId;
    /**
     * The name
     * Meta informations extracted from the WSDL
     * - nillable: true
     * @var string
     */
    public $name;
    /**
     * The surname1
     * Meta informations extracted from the WSDL
     * - nillable: true
     * @var string
     */
    public $surname1;
    /**
     * The surname2
     * Meta informations extracted from the WSDL
     * - nillable: true
     * @var string
     */
    public $surname2;
    /**
     * The address
     * Meta informations extracted from the WSDL
     * - nillable: true
     * @var string
     */
    public $address;
    /**
     * The email
     * Meta informations extracted from the WSDL
     * - nillable: true
     * @var string
     */
    public $email;
    /**
     * Constructor method for NotificationReceiver
     * @uses NotificationReceiver::setId()
     * @uses NotificationReceiver::setIdNotification()
     * @uses NotificationReceiver::setReceiverId()
     * @uses NotificationReceiver::setName()
     * @uses NotificationReceiver::setSurname1()
     * @uses NotificationReceiver::setSurname2()
     * @uses NotificationReceiver::setAddress()
     * @uses NotificationReceiver::setEmail()
     * @param int $id
     * @param int $idNotification
     * @param string $receiverId
     * @param string $name
     * @param string $surname1
     * @param string $surname2
     * @param string $address
     * @param string $email
     */
    public function __construct($id = null, $idNotification = null, $receiverId = null, $name = null, $surname1 = null, $surname2 = null, $address = null, $email = null)
    {
        $this
            ->setId($id)
            ->setIdNotification($idNotification)
            ->setReceiverId($receiverId)
            ->setName($name)
            ->setSurname1($surname1)
            ->setSurname2($surname2)
            ->setAddress($address)
            ->setEmail($email);
    }
    /**
     * Get id value
     * @return int|null
     */
    public function getId()
    {
        return $this->id;
    }
    /**
     * Set id value
     * @param int $id
     * @return NotificationReceiver
     */
    public function setId($id = null)
    {
        // validation for constraint: int
        if (!is_null($id) && !is_numeric($id)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a numeric value, "%s" given', gettype($id)), __LINE__);
        }
        $this->id = $id;
        return $this;
    }
    /**
     * Get idNotification value
     * @return int|null
     */
    public function getIdNotification()
    {
        return $this->idNotification;
    }
    /**
     * Set idNotification value
     * @param int $idNotification
     * @return NotificationReceiver
     */
    public function setIdNotification($idNotification = null)
    {
        // validation for constraint: int
        if (!is_null($idNotification) && !is_numeric($idNotification)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a numeric value, "%s" given', gettype($idNotification)), __LINE__);
        }
        $this->idNotification = $idNotification;
        return $this;
    }
    /**
     * Get receiverId value
     * @return string|null
     */
    public function getReceiverId()
    {
        return $this->receiverId;
    }
    /**
     * Set receiverId value
     * @param string $receiverId
     * @return NotificationReceiver
     */
    public function setReceiverId($receiverId = null)
    {
        // validation for constraint: string
        if (!is_null($receiverId) && !is_string($receiverId)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($receiverId)), __LINE__);
        }
        $this->receiverId = $receiverId;
        return $this;
    }
    /**
     * Get name value
     * @return string|null
     */
    public function getName()
    {
        return $this->name;
    }
    /**
     * Set name value
     * @param string $name
     * @return NotificationReceiver
     */
    public function setName($name = null)
    {
        // validation for constraint: string
        if (!is_null($name) && !is_string($name)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($name)), __LINE__);
        }
        $this->name = $name;
        return $this;
    }
    /**
     * Get surname1 value
     * @return string|null
     */
    public function getSurname1()
    {
        return $this->surname1;
    }
    /**
     * Set surname1 value
     * @param string $surname1
     * @return NotificationReceiver
     */
    public function setSurname1($surname1 = null)
    {
        // validation for constraint: string
        if (!is_null($surname1) && !is_string($surname1)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($surname1)), __LINE__);
        }
        $this->surname1 = $surname1;
        return $this;
    }
    /**
     * Get surname2 value
     * @return string|null
     */
    public function getSurname2()
    {
        return $this->surname2;
    }
    /**
     * Set surname2 value
     * @param string $surname2
     * @return NotificationReceiver
     */
    public function setSurname2($surname2 = null)
    {
        // validation for constraint: string
        if (!is_null($surname2) && !is_string($surname2)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($surname2)), __LINE__);
        }
        $this->surname2 = $surname2;
        return $this;
    }
    /**
     * Get address value
     * @return string|null
     */
    public function getAddress()
    {
        return $this->address;
    }
    /**
     * Set address value
     * @param string $address
     * @return NotificationReceiver
     */
    public function setAddress($address = null)
    {
        // validation for constraint: string
        if (!is_null($address) && !is_string($address)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($address)), __LINE__);
        }
        $this->address = $address;
        return $this;
    }
    /**
     * Get email value
     * @return string|null
     */
    public function getEmail()
    {
        return $this->email;
    }
    /**
     * Set email value
     * @param string $email
     * @return NotificationReceiver
     */
    public function setEmail($email = null)
    {
        // validation for constraint: string
        if (!is_null($email) && !is_string($email)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($email)), __LINE__);
        }
        $this->email = $email;
        return $this;
    }
    /**
     * Method called when an object has been exported with var_export() functions
     * It allows to return an object instantiated with the values
     * @see AbstractStructBase::__set_state()
     * @uses AbstractStructBase::__set_state()
     * @param array $array the exported values
     * @return NotificationReceiver
     */
    public static function __set_state(array $array)
    {
        return parent::__set_state($array);
    }
    /**
     * Method returning the class name
     * @return string __CLASS__
     */
    public function __toString()
    {
        return __CLASS__;
    }
}
