<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for JP_SearchSegmentRentacar StructType
 * @subpackage Structs
 */
class JP_SearchSegmentRentacar extends JP_SearchSegmentBase
{
    /**
     * The AgeDriver
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 1
     * @var int
     */
    public $AgeDriver;
    /**
     * The CountryOfResidence
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var string
     */
    public $CountryOfResidence;
    /**
     * The Hour
     * @var string
     */
    public $Hour;
    /**
     * The HourEnd
     * @var string
     */
    public $HourEnd;
    /**
     * The CarCategory
     * @var string
     */
    public $CarCategory;
    /**
     * The CarType
     * @var string
     */
    public $CarType;
    /**
     * The CarTransmission
     * @var string
     */
    public $CarTransmission;
    /**
     * The CarDriveAC
     * @var string
     */
    public $CarDriveAC;
    /**
     * Constructor method for JP_SearchSegmentRentacar
     * @uses JP_SearchSegmentRentacar::setAgeDriver()
     * @uses JP_SearchSegmentRentacar::setCountryOfResidence()
     * @uses JP_SearchSegmentRentacar::setHour()
     * @uses JP_SearchSegmentRentacar::setHourEnd()
     * @uses JP_SearchSegmentRentacar::setCarCategory()
     * @uses JP_SearchSegmentRentacar::setCarType()
     * @uses JP_SearchSegmentRentacar::setCarTransmission()
     * @uses JP_SearchSegmentRentacar::setCarDriveAC()
     * @param int $ageDriver
     * @param string $countryOfResidence
     * @param string $hour
     * @param string $hourEnd
     * @param string $carCategory
     * @param string $carType
     * @param string $carTransmission
     * @param string $carDriveAC
     */
    public function __construct($ageDriver = null, $countryOfResidence = null, $hour = null, $hourEnd = null, $carCategory = null, $carType = null, $carTransmission = null, $carDriveAC = null)
    {
        $this
            ->setAgeDriver($ageDriver)
            ->setCountryOfResidence($countryOfResidence)
            ->setHour($hour)
            ->setHourEnd($hourEnd)
            ->setCarCategory($carCategory)
            ->setCarType($carType)
            ->setCarTransmission($carTransmission)
            ->setCarDriveAC($carDriveAC);
    }
    /**
     * Get AgeDriver value
     * @return int
     */
    public function getAgeDriver()
    {
        return $this->AgeDriver;
    }
    /**
     * Set AgeDriver value
     * @param int $ageDriver
     * @return \StructType\JP_SearchSegmentRentacar
     */
    public function setAgeDriver($ageDriver = null)
    {
        // validation for constraint: int
        if (!is_null($ageDriver) && !(is_int($ageDriver) || ctype_digit($ageDriver))) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide an integer value, %s given', var_export($ageDriver, true), gettype($ageDriver)), __LINE__);
        }
        $this->AgeDriver = $ageDriver;
        return $this;
    }
    /**
     * Get CountryOfResidence value
     * @return string|null
     */
    public function getCountryOfResidence()
    {
        return $this->CountryOfResidence;
    }
    /**
     * Set CountryOfResidence value
     * @param string $countryOfResidence
     * @return \StructType\JP_SearchSegmentRentacar
     */
    public function setCountryOfResidence($countryOfResidence = null)
    {
        // validation for constraint: string
        if (!is_null($countryOfResidence) && !is_string($countryOfResidence)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($countryOfResidence, true), gettype($countryOfResidence)), __LINE__);
        }
        $this->CountryOfResidence = $countryOfResidence;
        return $this;
    }
    /**
     * Get Hour value
     * @return string|null
     */
    public function getHour()
    {
        return $this->Hour;
    }
    /**
     * Set Hour value
     * @param string $hour
     * @return \StructType\JP_SearchSegmentRentacar
     */
    public function setHour($hour = null)
    {
        // validation for constraint: string
        if (!is_null($hour) && !is_string($hour)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($hour, true), gettype($hour)), __LINE__);
        }
        $this->Hour = $hour;
        return $this;
    }
    /**
     * Get HourEnd value
     * @return string|null
     */
    public function getHourEnd()
    {
        return $this->HourEnd;
    }
    /**
     * Set HourEnd value
     * @param string $hourEnd
     * @return \StructType\JP_SearchSegmentRentacar
     */
    public function setHourEnd($hourEnd = null)
    {
        // validation for constraint: string
        if (!is_null($hourEnd) && !is_string($hourEnd)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($hourEnd, true), gettype($hourEnd)), __LINE__);
        }
        $this->HourEnd = $hourEnd;
        return $this;
    }
    /**
     * Get CarCategory value
     * @return string|null
     */
    public function getCarCategory()
    {
        return $this->CarCategory;
    }
    /**
     * Set CarCategory value
     * @param string $carCategory
     * @return \StructType\JP_SearchSegmentRentacar
     */
    public function setCarCategory($carCategory = null)
    {
        // validation for constraint: string
        if (!is_null($carCategory) && !is_string($carCategory)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($carCategory, true), gettype($carCategory)), __LINE__);
        }
        $this->CarCategory = $carCategory;
        return $this;
    }
    /**
     * Get CarType value
     * @return string|null
     */
    public function getCarType()
    {
        return $this->CarType;
    }
    /**
     * Set CarType value
     * @param string $carType
     * @return \StructType\JP_SearchSegmentRentacar
     */
    public function setCarType($carType = null)
    {
        // validation for constraint: string
        if (!is_null($carType) && !is_string($carType)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($carType, true), gettype($carType)), __LINE__);
        }
        $this->CarType = $carType;
        return $this;
    }
    /**
     * Get CarTransmission value
     * @return string|null
     */
    public function getCarTransmission()
    {
        return $this->CarTransmission;
    }
    /**
     * Set CarTransmission value
     * @param string $carTransmission
     * @return \StructType\JP_SearchSegmentRentacar
     */
    public function setCarTransmission($carTransmission = null)
    {
        // validation for constraint: string
        if (!is_null($carTransmission) && !is_string($carTransmission)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($carTransmission, true), gettype($carTransmission)), __LINE__);
        }
        $this->CarTransmission = $carTransmission;
        return $this;
    }
    /**
     * Get CarDriveAC value
     * @return string|null
     */
    public function getCarDriveAC()
    {
        return $this->CarDriveAC;
    }
    /**
     * Set CarDriveAC value
     * @param string $carDriveAC
     * @return \StructType\JP_SearchSegmentRentacar
     */
    public function setCarDriveAC($carDriveAC = null)
    {
        // validation for constraint: string
        if (!is_null($carDriveAC) && !is_string($carDriveAC)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($carDriveAC, true), gettype($carDriveAC)), __LINE__);
        }
        $this->CarDriveAC = $carDriveAC;
        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\JP_SearchSegmentRentacar
     */
    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__;
    }
}
