<?php

namespace patest\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for BizResource.CalendarMonthlyView StructType
 * @subpackage Structs
 */
class BizResource_CalendarMonthlyView extends BizResource_CalendarView
{
    /**
     * The Weeks
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\RecordSetOfBizResource_CalendarWeek
     */
    public $Weeks;
    /**
     * Constructor method for BizResource.CalendarMonthlyView
     * @uses BizResource_CalendarMonthlyView::setWeeks()
     * @param \patest\StructType\RecordSetOfBizResource_CalendarWeek $weeks
     */
    public function __construct(\patest\StructType\RecordSetOfBizResource_CalendarWeek $weeks = null)
    {
        $this
            ->setWeeks($weeks);
    }
    /**
     * Get Weeks 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\StructType\RecordSetOfBizResource_CalendarWeek|null
     */
    public function getWeeks()
    {
        return isset($this->Weeks) ? $this->Weeks : null;
    }
    /**
     * Set Weeks 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\StructType\RecordSetOfBizResource_CalendarWeek $weeks
     * @return \patest\StructType\BizResource_CalendarMonthlyView
     */
    public function setWeeks(\patest\StructType\RecordSetOfBizResource_CalendarWeek $weeks = null)
    {
        if (is_null($weeks) || (is_array($weeks) && empty($weeks))) {
            unset($this->Weeks);
        } else {
            $this->Weeks = $weeks;
        }
        return $this;
    }
}
