<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for ArtigoLoteERP StructType
 * Meta informations extracted from the WSDL
 * - nillable: true
 * - type: tns:ArtigoLoteERP
 * @subpackage Structs
 */
class ArtigoLoteERP extends AbstractStructBase
{
    /**
     * The Activo
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var bool
     */
    public $Activo;
    /**
     * The Artigo
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Artigo;
    /**
     * The Controlador
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Controlador;
    /**
     * The DataFabrico
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $DataFabrico;
    /**
     * The Descricao
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Descricao;
    /**
     * The Lote
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Lote;
    /**
     * The Observacoes
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Observacoes;
    /**
     * The Protegida
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * @var bool
     */
    public $Protegida;
    /**
     * The Validade
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Validade;
    /**
     * The VersaoUltAct
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * @var string
     */
    public $VersaoUltAct;
    /**
     * Constructor method for ArtigoLoteERP
     * @uses ArtigoLoteERP::setActivo()
     * @uses ArtigoLoteERP::setArtigo()
     * @uses ArtigoLoteERP::setControlador()
     * @uses ArtigoLoteERP::setDataFabrico()
     * @uses ArtigoLoteERP::setDescricao()
     * @uses ArtigoLoteERP::setLote()
     * @uses ArtigoLoteERP::setObservacoes()
     * @uses ArtigoLoteERP::setProtegida()
     * @uses ArtigoLoteERP::setValidade()
     * @uses ArtigoLoteERP::setVersaoUltAct()
     * @param bool $activo
     * @param string $artigo
     * @param string $controlador
     * @param string $dataFabrico
     * @param string $descricao
     * @param string $lote
     * @param string $observacoes
     * @param bool $protegida
     * @param string $validade
     * @param string $versaoUltAct
     */
    public function __construct($activo = null, $artigo = null, $controlador = null, $dataFabrico = null, $descricao = null, $lote = null, $observacoes = null, $protegida = null, $validade = null, $versaoUltAct = null)
    {
        $this
            ->setActivo($activo)
            ->setArtigo($artigo)
            ->setControlador($controlador)
            ->setDataFabrico($dataFabrico)
            ->setDescricao($descricao)
            ->setLote($lote)
            ->setObservacoes($observacoes)
            ->setProtegida($protegida)
            ->setValidade($validade)
            ->setVersaoUltAct($versaoUltAct);
    }
    /**
     * Get Activo 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 bool|null
     */
    public function getActivo()
    {
        return isset($this->Activo) ? $this->Activo : null;
    }
    /**
     * Set Activo 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 bool $activo
     * @return \StructType\ArtigoLoteERP
     */
    public function setActivo($activo = null)
    {
        // validation for constraint: boolean
        if (!is_null($activo) && !is_bool($activo)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a bool, "%s" given', gettype($activo)), __LINE__);
        }
        if (is_null($activo) || (is_array($activo) && empty($activo))) {
            unset($this->Activo);
        } else {
            $this->Activo = $activo;
        }
        return $this;
    }
    /**
     * Get Artigo 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 getArtigo()
    {
        return isset($this->Artigo) ? $this->Artigo : null;
    }
    /**
     * Set Artigo 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 $artigo
     * @return \StructType\ArtigoLoteERP
     */
    public function setArtigo($artigo = null)
    {
        // validation for constraint: string
        if (!is_null($artigo) && !is_string($artigo)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($artigo)), __LINE__);
        }
        if (is_null($artigo) || (is_array($artigo) && empty($artigo))) {
            unset($this->Artigo);
        } else {
            $this->Artigo = $artigo;
        }
        return $this;
    }
    /**
     * Get Controlador 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 getControlador()
    {
        return isset($this->Controlador) ? $this->Controlador : null;
    }
    /**
     * Set Controlador 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 $controlador
     * @return \StructType\ArtigoLoteERP
     */
    public function setControlador($controlador = null)
    {
        // validation for constraint: string
        if (!is_null($controlador) && !is_string($controlador)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($controlador)), __LINE__);
        }
        if (is_null($controlador) || (is_array($controlador) && empty($controlador))) {
            unset($this->Controlador);
        } else {
            $this->Controlador = $controlador;
        }
        return $this;
    }
    /**
     * Get DataFabrico 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 getDataFabrico()
    {
        return isset($this->DataFabrico) ? $this->DataFabrico : null;
    }
    /**
     * Set DataFabrico 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 $dataFabrico
     * @return \StructType\ArtigoLoteERP
     */
    public function setDataFabrico($dataFabrico = null)
    {
        // validation for constraint: string
        if (!is_null($dataFabrico) && !is_string($dataFabrico)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($dataFabrico)), __LINE__);
        }
        if (is_null($dataFabrico) || (is_array($dataFabrico) && empty($dataFabrico))) {
            unset($this->DataFabrico);
        } else {
            $this->DataFabrico = $dataFabrico;
        }
        return $this;
    }
    /**
     * Get Descricao 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 getDescricao()
    {
        return isset($this->Descricao) ? $this->Descricao : null;
    }
    /**
     * Set Descricao 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 $descricao
     * @return \StructType\ArtigoLoteERP
     */
    public function setDescricao($descricao = null)
    {
        // validation for constraint: string
        if (!is_null($descricao) && !is_string($descricao)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($descricao)), __LINE__);
        }
        if (is_null($descricao) || (is_array($descricao) && empty($descricao))) {
            unset($this->Descricao);
        } else {
            $this->Descricao = $descricao;
        }
        return $this;
    }
    /**
     * Get Lote 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 getLote()
    {
        return isset($this->Lote) ? $this->Lote : null;
    }
    /**
     * Set Lote 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 $lote
     * @return \StructType\ArtigoLoteERP
     */
    public function setLote($lote = null)
    {
        // validation for constraint: string
        if (!is_null($lote) && !is_string($lote)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($lote)), __LINE__);
        }
        if (is_null($lote) || (is_array($lote) && empty($lote))) {
            unset($this->Lote);
        } else {
            $this->Lote = $lote;
        }
        return $this;
    }
    /**
     * Get Observacoes 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 getObservacoes()
    {
        return isset($this->Observacoes) ? $this->Observacoes : null;
    }
    /**
     * Set Observacoes 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 $observacoes
     * @return \StructType\ArtigoLoteERP
     */
    public function setObservacoes($observacoes = null)
    {
        // validation for constraint: string
        if (!is_null($observacoes) && !is_string($observacoes)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($observacoes)), __LINE__);
        }
        if (is_null($observacoes) || (is_array($observacoes) && empty($observacoes))) {
            unset($this->Observacoes);
        } else {
            $this->Observacoes = $observacoes;
        }
        return $this;
    }
    /**
     * Get Protegida value
     * @return bool|null
     */
    public function getProtegida()
    {
        return $this->Protegida;
    }
    /**
     * Set Protegida value
     * @param bool $protegida
     * @return \StructType\ArtigoLoteERP
     */
    public function setProtegida($protegida = null)
    {
        // validation for constraint: boolean
        if (!is_null($protegida) && !is_bool($protegida)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a bool, "%s" given', gettype($protegida)), __LINE__);
        }
        $this->Protegida = $protegida;
        return $this;
    }
    /**
     * Get Validade 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 getValidade()
    {
        return isset($this->Validade) ? $this->Validade : null;
    }
    /**
     * Set Validade 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 $validade
     * @return \StructType\ArtigoLoteERP
     */
    public function setValidade($validade = null)
    {
        // validation for constraint: string
        if (!is_null($validade) && !is_string($validade)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($validade)), __LINE__);
        }
        if (is_null($validade) || (is_array($validade) && empty($validade))) {
            unset($this->Validade);
        } else {
            $this->Validade = $validade;
        }
        return $this;
    }
    /**
     * Get VersaoUltAct value
     * @return string|null
     */
    public function getVersaoUltAct()
    {
        return $this->VersaoUltAct;
    }
    /**
     * Set VersaoUltAct value
     * @param string $versaoUltAct
     * @return \StructType\ArtigoLoteERP
     */
    public function setVersaoUltAct($versaoUltAct = null)
    {
        // validation for constraint: string
        if (!is_null($versaoUltAct) && !is_string($versaoUltAct)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($versaoUltAct)), __LINE__);
        }
        $this->VersaoUltAct = $versaoUltAct;
        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 \StructType\ArtigoLoteERP
     */
    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__;
    }
}
