<?php

namespace patest\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

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