<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for JP_CruiseBookingRulesAdvancedOptions StructType
 * @subpackage Structs
 */
class JP_CruiseBookingRulesAdvancedOptions extends JP_BookingRulesAdvancedOptions
{
    /**
     * The ShowCruiseInfo
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var bool
     */
    public $ShowCruiseInfo;
    /**
     * Constructor method for JP_CruiseBookingRulesAdvancedOptions
     * @uses JP_CruiseBookingRulesAdvancedOptions::setShowCruiseInfo()
     * @param bool $showCruiseInfo
     */
    public function __construct($showCruiseInfo = null)
    {
        $this
            ->setShowCruiseInfo($showCruiseInfo);
    }
    /**
     * Get ShowCruiseInfo value
     * @return bool|null
     */
    public function getShowCruiseInfo()
    {
        return $this->ShowCruiseInfo;
    }
    /**
     * Set ShowCruiseInfo value
     * @param bool $showCruiseInfo
     * @return \StructType\JP_CruiseBookingRulesAdvancedOptions
     */
    public function setShowCruiseInfo($showCruiseInfo = null)
    {
        // validation for constraint: boolean
        if (!is_null($showCruiseInfo) && !is_bool($showCruiseInfo)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a bool, %s given', var_export($showCruiseInfo, true), gettype($showCruiseInfo)), __LINE__);
        }
        $this->ShowCruiseInfo = $showCruiseInfo;
        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_CruiseBookingRulesAdvancedOptions
     */
    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__;
    }
}
