<?php

namespace Sabre\OTAPing\Structs;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for RateComments Structs
 * Meta informations extracted from the WSDL
 * - documentation: Collection of rate comments.
 * @subpackage Structs
 */
class RateComments extends AbstractStructBase
{
    /**
     * The RateComment
     * Meta informations extracted from the WSDL
     * - maxOccurs: 15
     * @var \Sabre\OTAPing\Structs\RateComment[]
     */
    public $RateComment;
    /**
     * Constructor method for RateComments
     * @uses RateComments::setRateComment()
     * @param \Sabre\OTAPing\Structs\RateComment[] $rateComment
     */
    public function __construct(array $rateComment = array())
    {
        $this
            ->setRateComment($rateComment);
    }
    /**
     * Get RateComment value
     * @return \Sabre\OTAPing\Structs\RateComment[]|null
     */
    public function getRateComment()
    {
        return $this->RateComment;
    }
    /**
     * Set RateComment value
     * @throws \InvalidArgumentException
     * @param \Sabre\OTAPing\Structs\RateComment[] $rateComment
     * @return \Sabre\OTAPing\Structs\RateComments
     */
    public function setRateComment(array $rateComment = array())
    {
        $this->RateComment = $rateComment;
        return $this;
    }
    /**
     * Add item to RateComment value
     * @throws \InvalidArgumentException
     * @param \Sabre\OTAPing\Structs\RateComment $item
     * @return \Sabre\OTAPing\Structs\RateComments
     */
    public function addToRateComment(\Sabre\OTAPing\Structs\RateComment $item)
    {
        $this->RateComment[] = $item;
        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 \Sabre\OTAPing\Structs\RateComments
     */
    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__;
    }
}
