<?php

namespace dgsoft\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for OTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
 * StructType
 * @package Dg
 * @subpackage Structs
 */
class DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan extends AbstractStructBase
{
    /**
     * The PlanDetail
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanPlanDetail
     */
    public $PlanDetail;
    /**
     * The ProviderDetail
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanProviderDetail
     */
    public $ProviderDetail;
    /**
     * The UnderwriterDetail
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanUnderwriterDetail
     */
    public $UnderwriterDetail;
    /**
     * The PlanCost
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \dgsoft\StructType\DgPlanCostType
     */
    public $PlanCost;
    /**
     * The PlanRestrictions
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \dgsoft\ArrayType\DgArrayOfPlanRestrictionTypePlanRestriction
     */
    public $PlanRestrictions;
    /**
     * The Featured
     * @var bool
     */
    public $Featured;
    /**
     * The PreferLevel
     * @var string
     */
    public $PreferLevel;
    /**
     * The PlanCode
     * @var string
     */
    public $PlanCode;
    /**
     * The PlanID
     * @var string
     */
    public $PlanID;
    /**
     * The Name
     * @var string
     */
    public $Name;
    /**
     * The Type
     * @var string
     */
    public $Type;
    /**
     * The TypeID
     * @var string
     */
    public $TypeID;
    /**
     * The EffectiveDate
     * @var string
     */
    public $EffectiveDate;
    /**
     * The ExpireDate
     * @var string
     */
    public $ExpireDate;
    /**
     * Constructor method for OTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setPlanDetail()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setProviderDetail()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setUnderwriterDetail()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setPlanCost()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setPlanRestrictions()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setFeatured()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setPreferLevel()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setPlanCode()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setPlanID()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setName()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setType()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setTypeID()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setEffectiveDate()
     * @uses DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan::setExpireDate()
     * @param \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanPlanDetail $planDetail
     * @param \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanProviderDetail $providerDetail
     * @param \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanUnderwriterDetail $underwriterDetail
     * @param \dgsoft\StructType\DgPlanCostType $planCost
     * @param \dgsoft\ArrayType\DgArrayOfPlanRestrictionTypePlanRestriction $planRestrictions
     * @param bool $featured
     * @param string $preferLevel
     * @param string $planCode
     * @param string $planID
     * @param string $name
     * @param string $type
     * @param string $typeID
     * @param string $effectiveDate
     * @param string $expireDate
     */
    public function __construct(\dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanPlanDetail $planDetail = null, \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanProviderDetail $providerDetail = null, \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanUnderwriterDetail $underwriterDetail = null, \dgsoft\StructType\DgPlanCostType $planCost = null, \dgsoft\ArrayType\DgArrayOfPlanRestrictionTypePlanRestriction $planRestrictions = null, $featured = null, $preferLevel = null, $planCode = null, $planID = null, $name = null, $type = null, $typeID = null, $effectiveDate = null, $expireDate = null)
    {
        $this
            ->setPlanDetail($planDetail)
            ->setProviderDetail($providerDetail)
            ->setUnderwriterDetail($underwriterDetail)
            ->setPlanCost($planCost)
            ->setPlanRestrictions($planRestrictions)
            ->setFeatured($featured)
            ->setPreferLevel($preferLevel)
            ->setPlanCode($planCode)
            ->setPlanID($planID)
            ->setName($name)
            ->setType($type)
            ->setTypeID($typeID)
            ->setEffectiveDate($effectiveDate)
            ->setExpireDate($expireDate);
    }
    /**
     * Get PlanDetail value
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanPlanDetail|null
     */
    public function getPlanDetail()
    {
        return $this->PlanDetail;
    }
    /**
     * Set PlanDetail value
     * @param \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanPlanDetail $planDetail
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setPlanDetail(\dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanPlanDetail $planDetail = null)
    {
        $this->PlanDetail = $planDetail;
        return $this;
    }
    /**
     * Get ProviderDetail value
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanProviderDetail|null
     */
    public function getProviderDetail()
    {
        return $this->ProviderDetail;
    }
    /**
     * Set ProviderDetail value
     * @param \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanProviderDetail $providerDetail
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setProviderDetail(\dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanProviderDetail $providerDetail = null)
    {
        $this->ProviderDetail = $providerDetail;
        return $this;
    }
    /**
     * Get UnderwriterDetail value
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanUnderwriterDetail|null
     */
    public function getUnderwriterDetail()
    {
        return $this->UnderwriterDetail;
    }
    /**
     * Set UnderwriterDetail value
     * @param \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanUnderwriterDetail $underwriterDetail
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setUnderwriterDetail(\dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlanUnderwriterDetail $underwriterDetail = null)
    {
        $this->UnderwriterDetail = $underwriterDetail;
        return $this;
    }
    /**
     * Get PlanCost value
     * @return \dgsoft\StructType\DgPlanCostType|null
     */
    public function getPlanCost()
    {
        return $this->PlanCost;
    }
    /**
     * Set PlanCost value
     * @param \dgsoft\StructType\DgPlanCostType $planCost
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setPlanCost(\dgsoft\StructType\DgPlanCostType $planCost = null)
    {
        $this->PlanCost = $planCost;
        return $this;
    }
    /**
     * Get PlanRestrictions value
     * @return \dgsoft\ArrayType\DgArrayOfPlanRestrictionTypePlanRestriction|null
     */
    public function getPlanRestrictions()
    {
        return $this->PlanRestrictions;
    }
    /**
     * Set PlanRestrictions value
     * @param \dgsoft\ArrayType\DgArrayOfPlanRestrictionTypePlanRestriction $planRestrictions
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setPlanRestrictions(\dgsoft\ArrayType\DgArrayOfPlanRestrictionTypePlanRestriction $planRestrictions = null)
    {
        $this->PlanRestrictions = $planRestrictions;
        return $this;
    }
    /**
     * Get Featured value
     * @return bool|null
     */
    public function getFeatured()
    {
        return $this->Featured;
    }
    /**
     * Set Featured value
     * @param bool $featured
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setFeatured($featured = null)
    {
        // validation for constraint: boolean
        if (!is_null($featured) && !is_bool($featured)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a bool, "%s" given', gettype($featured)), __LINE__);
        }
        $this->Featured = $featured;
        return $this;
    }
    /**
     * Get PreferLevel value
     * @return string|null
     */
    public function getPreferLevel()
    {
        return $this->PreferLevel;
    }
    /**
     * Set PreferLevel value
     * @uses \dgsoft\EnumType\DgPreferLevelType::valueIsValid()
     * @uses \dgsoft\EnumType\DgPreferLevelType::getValidValues()
     * @throws \InvalidArgumentException
     * @param string $preferLevel
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setPreferLevel($preferLevel = null)
    {
        // validation for constraint: enumeration
        if (!\dgsoft\EnumType\DgPreferLevelType::valueIsValid($preferLevel)) {
            throw new \InvalidArgumentException(sprintf('Value "%s" is invalid, please use one of: %s', $preferLevel, implode(', ', \dgsoft\EnumType\DgPreferLevelType::getValidValues())), __LINE__);
        }
        $this->PreferLevel = $preferLevel;
        return $this;
    }
    /**
     * Get PlanCode value
     * @return string|null
     */
    public function getPlanCode()
    {
        return $this->PlanCode;
    }
    /**
     * Set PlanCode value
     * @param string $planCode
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setPlanCode($planCode = null)
    {
        // validation for constraint: string
        if (!is_null($planCode) && !is_string($planCode)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($planCode)), __LINE__);
        }
        $this->PlanCode = $planCode;
        return $this;
    }
    /**
     * Get PlanID value
     * @return string|null
     */
    public function getPlanID()
    {
        return $this->PlanID;
    }
    /**
     * Set PlanID value
     * @param string $planID
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setPlanID($planID = null)
    {
        // validation for constraint: string
        if (!is_null($planID) && !is_string($planID)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($planID)), __LINE__);
        }
        $this->PlanID = $planID;
        return $this;
    }
    /**
     * Get Name value
     * @return string|null
     */
    public function getName()
    {
        return $this->Name;
    }
    /**
     * Set Name value
     * @param string $name
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    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 Type value
     * @return string|null
     */
    public function getType()
    {
        return $this->Type;
    }
    /**
     * Set Type value
     * @param string $type
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setType($type = null)
    {
        // validation for constraint: string
        if (!is_null($type) && !is_string($type)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($type)), __LINE__);
        }
        $this->Type = $type;
        return $this;
    }
    /**
     * Get TypeID value
     * @return string|null
     */
    public function getTypeID()
    {
        return $this->TypeID;
    }
    /**
     * Set TypeID value
     * @param string $typeID
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setTypeID($typeID = null)
    {
        // validation for constraint: string
        if (!is_null($typeID) && !is_string($typeID)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($typeID)), __LINE__);
        }
        $this->TypeID = $typeID;
        return $this;
    }
    /**
     * Get EffectiveDate value
     * @return string|null
     */
    public function getEffectiveDate()
    {
        return $this->EffectiveDate;
    }
    /**
     * Set EffectiveDate value
     * @param string $effectiveDate
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setEffectiveDate($effectiveDate = null)
    {
        // validation for constraint: string
        if (!is_null($effectiveDate) && !is_string($effectiveDate)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($effectiveDate)), __LINE__);
        }
        $this->EffectiveDate = $effectiveDate;
        return $this;
    }
    /**
     * Get ExpireDate value
     * @return string|null
     */
    public function getExpireDate()
    {
        return $this->ExpireDate;
    }
    /**
     * Set ExpireDate value
     * @param string $expireDate
     * @return \dgsoft\StructType\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    public function setExpireDate($expireDate = null)
    {
        // validation for constraint: string
        if (!is_null($expireDate) && !is_string($expireDate)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($expireDate)), __LINE__);
        }
        $this->ExpireDate = $expireDate;
        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\DgOTA_InsurancePlanSearchRSAvailablePlansAvailablePlan
     */
    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__;
    }
}
