<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for JPSOAP_BookingInAdvance StructType
 * @subpackage Structs
 */
class JPSOAP_BookingInAdvance extends AbstractStructBase
{
    /**
     * The MinDays
     * @var int
     */
    public $MinDays;
    /**
     * The MaxDays
     * @var int
     */
    public $MaxDays;
    /**
     * Constructor method for JPSOAP_BookingInAdvance
     * @uses JPSOAP_BookingInAdvance::setMinDays()
     * @uses JPSOAP_BookingInAdvance::setMaxDays()
     * @param int $minDays
     * @param int $maxDays
     */
    public function __construct($minDays = null, $maxDays = null)
    {
        $this
            ->setMinDays($minDays)
            ->setMaxDays($maxDays);
    }
    /**
     * Get MinDays value
     * @return int|null
     */
    public function getMinDays()
    {
        return $this->MinDays;
    }
    /**
     * Set MinDays value
     * @param int $minDays
     * @return \StructType\JPSOAP_BookingInAdvance
     */
    public function setMinDays($minDays = null)
    {
        // validation for constraint: int
        if (!is_null($minDays) && !(is_int($minDays) || ctype_digit($minDays))) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide an integer value, %s given', var_export($minDays, true), gettype($minDays)), __LINE__);
        }
        $this->MinDays = $minDays;
        return $this;
    }
    /**
     * Get MaxDays value
     * @return int|null
     */
    public function getMaxDays()
    {
        return $this->MaxDays;
    }
    /**
     * Set MaxDays value
     * @param int $maxDays
     * @return \StructType\JPSOAP_BookingInAdvance
     */
    public function setMaxDays($maxDays = null)
    {
        // validation for constraint: int
        if (!is_null($maxDays) && !(is_int($maxDays) || ctype_digit($maxDays))) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide an integer value, %s given', var_export($maxDays, true), gettype($maxDays)), __LINE__);
        }
        $this->MaxDays = $maxDays;
        return $this;
    }
}
