<?php

namespace patest\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for Payment.AddCustomDummyCashPaymentToBasketRequest
 * StructType
 * @subpackage Structs
 */
class Payment_AddCustomDummyCashPaymentToBasketRequest extends Payment_AddPaymentToBasketRequestBase
{
    /**
     * The Changed
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\Money
     */
    public $Changed;
    /**
     * The ReceivedSum
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\Money
     */
    public $ReceivedSum;
    /**
     * Constructor method for Payment.AddCustomDummyCashPaymentToBasketRequest
     * @uses Payment_AddCustomDummyCashPaymentToBasketRequest::setChanged()
     * @uses Payment_AddCustomDummyCashPaymentToBasketRequest::setReceivedSum()
     * @param \patest\StructType\Money $changed
     * @param \patest\StructType\Money $receivedSum
     */
    public function __construct(\patest\StructType\Money $changed = null, \patest\StructType\Money $receivedSum = null)
    {
        $this
            ->setChanged($changed)
            ->setReceivedSum($receivedSum);
    }
    /**
     * Get Changed 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\Money|null
     */
    public function getChanged()
    {
        return isset($this->Changed) ? $this->Changed : null;
    }
    /**
     * Set Changed 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\Money $changed
     * @return \patest\StructType\Payment_AddCustomDummyCashPaymentToBasketRequest
     */
    public function setChanged(\patest\StructType\Money $changed = null)
    {
        if (is_null($changed) || (is_array($changed) && empty($changed))) {
            unset($this->Changed);
        } else {
            $this->Changed = $changed;
        }
        return $this;
    }
    /**
     * Get ReceivedSum 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\Money|null
     */
    public function getReceivedSum()
    {
        return isset($this->ReceivedSum) ? $this->ReceivedSum : null;
    }
    /**
     * Set ReceivedSum 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\Money $receivedSum
     * @return \patest\StructType\Payment_AddCustomDummyCashPaymentToBasketRequest
     */
    public function setReceivedSum(\patest\StructType\Money $receivedSum = null)
    {
        if (is_null($receivedSum) || (is_array($receivedSum) && empty($receivedSum))) {
            unset($this->ReceivedSum);
        } else {
            $this->ReceivedSum = $receivedSum;
        }
        return $this;
    }
}
