<?php

namespace patest\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for GetBundleElementAvailableDatesResponse StructType
 * Meta information extracted from the WSDL
 * - nillable: true
 * - type: tns:GetBundleElementAvailableDatesResponse
 * @subpackage Structs
 */
class GetBundleElementAvailableDatesResponse extends ExtensibleDataContract
{
    /**
     * The AvaliablityInfo
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\ArrayType\ArrayOfBundleAvailabilityInfo
     */
    public $AvaliablityInfo;
    /**
     * Constructor method for GetBundleElementAvailableDatesResponse
     * @uses GetBundleElementAvailableDatesResponse::setAvaliablityInfo()
     * @param \patest\ArrayType\ArrayOfBundleAvailabilityInfo $avaliablityInfo
     */
    public function __construct(\patest\ArrayType\ArrayOfBundleAvailabilityInfo $avaliablityInfo = null)
    {
        $this
            ->setAvaliablityInfo($avaliablityInfo);
    }
    /**
     * Get AvaliablityInfo 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 \patest\ArrayType\ArrayOfBundleAvailabilityInfo|null
     */
    public function getAvaliablityInfo()
    {
        return isset($this->AvaliablityInfo) ? $this->AvaliablityInfo : null;
    }
    /**
     * Set AvaliablityInfo 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 \patest\ArrayType\ArrayOfBundleAvailabilityInfo $avaliablityInfo
     * @return \patest\StructType\GetBundleElementAvailableDatesResponse
     */
    public function setAvaliablityInfo(\patest\ArrayType\ArrayOfBundleAvailabilityInfo $avaliablityInfo = null)
    {
        if (is_null($avaliablityInfo) || (is_array($avaliablityInfo) && empty($avaliablityInfo))) {
            unset($this->AvaliablityInfo);
        } else {
            $this->AvaliablityInfo = $avaliablityInfo;
        }
        return $this;
    }
}
