<?php

namespace patest\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for SuggestRefundOptionsResponse StructType
 * Meta information extracted from the WSDL
 * - nillable: true
 * - type: tns:SuggestRefundOptionsResponse
 * @subpackage Structs
 */
class SuggestRefundOptionsResponse extends AbstractStructBase
{
    /**
     * The RefundOptions
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\ArrayType\ArrayOfRefundOptionDescription
     */
    public $RefundOptions;
    /**
     * Constructor method for SuggestRefundOptionsResponse
     * @uses SuggestRefundOptionsResponse::setRefundOptions()
     * @param \patest\ArrayType\ArrayOfRefundOptionDescription $refundOptions
     */
    public function __construct(\patest\ArrayType\ArrayOfRefundOptionDescription $refundOptions = null)
    {
        $this
            ->setRefundOptions($refundOptions);
    }
    /**
     * Get RefundOptions 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\ArrayType\ArrayOfRefundOptionDescription|null
     */
    public function getRefundOptions()
    {
        return isset($this->RefundOptions) ? $this->RefundOptions : null;
    }
    /**
     * Set RefundOptions 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\ArrayType\ArrayOfRefundOptionDescription $refundOptions
     * @return \patest\StructType\SuggestRefundOptionsResponse
     */
    public function setRefundOptions(\patest\ArrayType\ArrayOfRefundOptionDescription $refundOptions = null)
    {
        if (is_null($refundOptions) || (is_array($refundOptions) && empty($refundOptions))) {
            unset($this->RefundOptions);
        } else {
            $this->RefundOptions = $refundOptions;
        }
        return $this;
    }
}
