<?php
use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for localRouteGroup StructType
 * @subpackage Structs
 */
class LocalRouteGroup extends AbstractStructBase
{
    /**
     * The name
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $name;
    /**
     * The value
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * - nillable: false
     * @var string
     */
    public $value;
    /**
     * The description
     * @var string
     */
    public $description;
    /**
     * The newName
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: false
     * @var string
     */
    public $newName;
    /**
     * The newDescription
     * Meta informations extracted from the WSDL
     * - minOccurs: 0
     * - nillable: false
     * @var string
     */
    public $newDescription;
    /**
     * Constructor method for localRouteGroup
     * @uses LocalRouteGroup::setName()
     * @uses LocalRouteGroup::setValue()
     * @uses LocalRouteGroup::setDescription()
     * @uses LocalRouteGroup::setNewName()
     * @uses LocalRouteGroup::setNewDescription()
     * @param string $name
     * @param string $value
     * @param string $description
     * @param string $newName
     * @param string $newDescription
     */
    public function __construct($name = null, $value = null, $description = null, $newName = null, $newDescription = null)
    {
        $this
            ->setName($name)
            ->setValue($value)
            ->setDescription($description)
            ->setNewName($newName)
            ->setNewDescription($newDescription);
    }
    /**
     * Get name value
     * @return string|null
     */
    public function getName()
    {
        return $this->name;
    }
    /**
     * Set name value
     * @param string $name
     * @return LocalRouteGroup
     */
    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 value value
     * @return string|null
     */
    public function getValue()
    {
        return $this->value;
    }
    /**
     * Set value value
     * @param string $value
     * @return LocalRouteGroup
     */
    public function setValue($value = null)
    {
        // validation for constraint: string
        if (!is_null($value) && !is_string($value)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($value)), __LINE__);
        }
        $this->value = $value;
        return $this;
    }
    /**
     * Get description value
     * @return string|null
     */
    public function getDescription()
    {
        return $this->description;
    }
    /**
     * Set description value
     * @param string $description
     * @return LocalRouteGroup
     */
    public function setDescription($description = null)
    {
        // validation for constraint: string
        if (!is_null($description) && !is_string($description)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($description)), __LINE__);
        }
        $this->description = $description;
        return $this;
    }
    /**
     * Get newName value
     * @return string|null
     */
    public function getNewName()
    {
        return $this->newName;
    }
    /**
     * Set newName value
     * @param string $newName
     * @return LocalRouteGroup
     */
    public function setNewName($newName = null)
    {
        // validation for constraint: string
        if (!is_null($newName) && !is_string($newName)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($newName)), __LINE__);
        }
        $this->newName = $newName;
        return $this;
    }
    /**
     * Get newDescription value
     * @return string|null
     */
    public function getNewDescription()
    {
        return $this->newDescription;
    }
    /**
     * Set newDescription value
     * @param string $newDescription
     * @return LocalRouteGroup
     */
    public function setNewDescription($newDescription = null)
    {
        // validation for constraint: string
        if (!is_null($newDescription) && !is_string($newDescription)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($newDescription)), __LINE__);
        }
        $this->newDescription = $newDescription;
        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 LocalRouteGroup
     */
    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__;
    }
}
