<?php

namespace dgsoft\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for VehicleVendorAvailabilityType StructType
 * @package Dg
 * @subpackage Structs
 */
class DgVehicleVendorAvailabilityType extends AbstractStructBase
{
    /**
     * The VehRentalCore
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \dgsoft\StructType\DgVehicleRentalCoreType
     */
    public $VehRentalCore;
    /**
     * The Vendor
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \dgsoft\StructType\DgCompanyNameType
     */
    public $Vendor;
    /**
     * The VehAvails
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \dgsoft\StructType\DgVehicleVendorAvailabilityTypeVehAvails
     */
    public $VehAvails;
    /**
     * The Info
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \dgsoft\StructType\DgVehicleAvailVendorInfoType
     */
    public $Info;
    /**
     * The VendorId
     * @var int
     */
    public $VendorId;
    /**
     * Constructor method for VehicleVendorAvailabilityType
     * @uses DgVehicleVendorAvailabilityType::setVehRentalCore()
     * @uses DgVehicleVendorAvailabilityType::setVendor()
     * @uses DgVehicleVendorAvailabilityType::setVehAvails()
     * @uses DgVehicleVendorAvailabilityType::setInfo()
     * @uses DgVehicleVendorAvailabilityType::setVendorId()
     * @param \dgsoft\StructType\DgVehicleRentalCoreType $vehRentalCore
     * @param \dgsoft\StructType\DgCompanyNameType $vendor
     * @param \dgsoft\StructType\DgVehicleVendorAvailabilityTypeVehAvails $vehAvails
     * @param \dgsoft\StructType\DgVehicleAvailVendorInfoType $info
     * @param int $vendorId
     */
    public function __construct(\dgsoft\StructType\DgVehicleRentalCoreType $vehRentalCore = null, \dgsoft\StructType\DgCompanyNameType $vendor = null, \dgsoft\StructType\DgVehicleVendorAvailabilityTypeVehAvails $vehAvails = null, \dgsoft\StructType\DgVehicleAvailVendorInfoType $info = null, $vendorId = null)
    {
        $this
            ->setVehRentalCore($vehRentalCore)
            ->setVendor($vendor)
            ->setVehAvails($vehAvails)
            ->setInfo($info)
            ->setVendorId($vendorId);
    }
    /**
     * Get VehRentalCore value
     * @return \dgsoft\StructType\DgVehicleRentalCoreType|null
     */
    public function getVehRentalCore()
    {
        return $this->VehRentalCore;
    }
    /**
     * Set VehRentalCore value
     * @param \dgsoft\StructType\DgVehicleRentalCoreType $vehRentalCore
     * @return \dgsoft\StructType\DgVehicleVendorAvailabilityType
     */
    public function setVehRentalCore(\dgsoft\StructType\DgVehicleRentalCoreType $vehRentalCore = null)
    {
        $this->VehRentalCore = $vehRentalCore;
        return $this;
    }
    /**
     * Get Vendor value
     * @return \dgsoft\StructType\DgCompanyNameType|null
     */
    public function getVendor()
    {
        return $this->Vendor;
    }
    /**
     * Set Vendor value
     * @param \dgsoft\StructType\DgCompanyNameType $vendor
     * @return \dgsoft\StructType\DgVehicleVendorAvailabilityType
     */
    public function setVendor(\dgsoft\StructType\DgCompanyNameType $vendor = null)
    {
        $this->Vendor = $vendor;
        return $this;
    }
    /**
     * Get VehAvails value
     * @return \dgsoft\StructType\DgVehicleVendorAvailabilityTypeVehAvails|null
     */
    public function getVehAvails()
    {
        return $this->VehAvails;
    }
    /**
     * Set VehAvails value
     * @param \dgsoft\StructType\DgVehicleVendorAvailabilityTypeVehAvails $vehAvails
     * @return \dgsoft\StructType\DgVehicleVendorAvailabilityType
     */
    public function setVehAvails(\dgsoft\StructType\DgVehicleVendorAvailabilityTypeVehAvails $vehAvails = null)
    {
        $this->VehAvails = $vehAvails;
        return $this;
    }
    /**
     * Get Info value
     * @return \dgsoft\StructType\DgVehicleAvailVendorInfoType|null
     */
    public function getInfo()
    {
        return $this->Info;
    }
    /**
     * Set Info value
     * @param \dgsoft\StructType\DgVehicleAvailVendorInfoType $info
     * @return \dgsoft\StructType\DgVehicleVendorAvailabilityType
     */
    public function setInfo(\dgsoft\StructType\DgVehicleAvailVendorInfoType $info = null)
    {
        $this->Info = $info;
        return $this;
    }
    /**
     * Get VendorId value
     * @return int|null
     */
    public function getVendorId()
    {
        return $this->VendorId;
    }
    /**
     * Set VendorId value
     * @param int $vendorId
     * @return \dgsoft\StructType\DgVehicleVendorAvailabilityType
     */
    public function setVendorId($vendorId = null)
    {
        // validation for constraint: int
        if (!is_null($vendorId) && !is_numeric($vendorId)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a numeric value, "%s" given', gettype($vendorId)), __LINE__);
        }
        $this->VendorId = $vendorId;
        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 \dgsoft\StructType\DgVehicleVendorAvailabilityType
     */
    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__;
    }
}
