<?php
use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for RiassegnaMezzoMissioni_Request StructType
 * Meta information extracted from the WSDL
 * - nillable: true
 * - type: tns:RiassegnaMezzoMissioni_Request
 * @subpackage Structs
 */
class RiassegnaMezzoMissioni_Request extends AbstractStructBase
{
    /**
     * The MezzoNew
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $MezzoNew;
    /**
     * The MezzoOld
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $MezzoOld;
    /**
     * The Missioni
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var ArrayOfMissioneBase_Model
     */
    public $Missioni;
    /**
     * Constructor method for RiassegnaMezzoMissioni_Request
     * @uses RiassegnaMezzoMissioni_Request::setMezzoNew()
     * @uses RiassegnaMezzoMissioni_Request::setMezzoOld()
     * @uses RiassegnaMezzoMissioni_Request::setMissioni()
     * @param string $mezzoNew
     * @param string $mezzoOld
     * @param ArrayOfMissioneBase_Model $missioni
     */
    public function __construct($mezzoNew = null, $mezzoOld = null, ArrayOfMissioneBase_Model $missioni = null)
    {
        $this
            ->setMezzoNew($mezzoNew)
            ->setMezzoOld($mezzoOld)
            ->setMissioni($missioni);
    }
    /**
     * Get MezzoNew 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 getMezzoNew()
    {
        return isset($this->MezzoNew) ? $this->MezzoNew : null;
    }
    /**
     * Set MezzoNew 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 $mezzoNew
     * @return RiassegnaMezzoMissioni_Request
     */
    public function setMezzoNew($mezzoNew = null)
    {
        // validation for constraint: string
        if (!is_null($mezzoNew) && !is_string($mezzoNew)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($mezzoNew, true), gettype($mezzoNew)), __LINE__);
        }
        if (is_null($mezzoNew) || (is_array($mezzoNew) && empty($mezzoNew))) {
            unset($this->MezzoNew);
        } else {
            $this->MezzoNew = $mezzoNew;
        }
        return $this;
    }
    /**
     * Get MezzoOld 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 getMezzoOld()
    {
        return isset($this->MezzoOld) ? $this->MezzoOld : null;
    }
    /**
     * Set MezzoOld 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 $mezzoOld
     * @return RiassegnaMezzoMissioni_Request
     */
    public function setMezzoOld($mezzoOld = null)
    {
        // validation for constraint: string
        if (!is_null($mezzoOld) && !is_string($mezzoOld)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($mezzoOld, true), gettype($mezzoOld)), __LINE__);
        }
        if (is_null($mezzoOld) || (is_array($mezzoOld) && empty($mezzoOld))) {
            unset($this->MezzoOld);
        } else {
            $this->MezzoOld = $mezzoOld;
        }
        return $this;
    }
    /**
     * Get Missioni 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 ArrayOfMissioneBase_Model|null
     */
    public function getMissioni()
    {
        return isset($this->Missioni) ? $this->Missioni : null;
    }
    /**
     * Set Missioni 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 ArrayOfMissioneBase_Model $missioni
     * @return RiassegnaMezzoMissioni_Request
     */
    public function setMissioni(ArrayOfMissioneBase_Model $missioni = null)
    {
        if (is_null($missioni) || (is_array($missioni) && empty($missioni))) {
            unset($this->Missioni);
        } else {
            $this->Missioni = $missioni;
        }
        return $this;
    }
}
