<?php

namespace patest\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for CreatePaymentContextResponse StructType
 * Meta information extracted from the WSDL
 * - nillable: true
 * - type: tns:CreatePaymentContextResponse
 * @subpackage Structs
 */
class CreatePaymentContextResponse extends AbstractStructBase
{
    /**
     * The Configurations
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\ArrayType\ArrayOfSessionServiceConfigurationDto
     */
    public $Configurations;
    /**
     * The Content
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Content;
    /**
     * The Resources
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\ArrayType\ArrayOfAssetResource
     */
    public $Resources;
    /**
     * Constructor method for CreatePaymentContextResponse
     * @uses CreatePaymentContextResponse::setConfigurations()
     * @uses CreatePaymentContextResponse::setContent()
     * @uses CreatePaymentContextResponse::setResources()
     * @param \patest\ArrayType\ArrayOfSessionServiceConfigurationDto $configurations
     * @param string $content
     * @param \patest\ArrayType\ArrayOfAssetResource $resources
     */
    public function __construct(\patest\ArrayType\ArrayOfSessionServiceConfigurationDto $configurations = null, $content = null, \patest\ArrayType\ArrayOfAssetResource $resources = null)
    {
        $this
            ->setConfigurations($configurations)
            ->setContent($content)
            ->setResources($resources);
    }
    /**
     * Get Configurations 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\ArrayOfSessionServiceConfigurationDto|null
     */
    public function getConfigurations()
    {
        return isset($this->Configurations) ? $this->Configurations : null;
    }
    /**
     * Set Configurations 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\ArrayOfSessionServiceConfigurationDto $configurations
     * @return \patest\StructType\CreatePaymentContextResponse
     */
    public function setConfigurations(\patest\ArrayType\ArrayOfSessionServiceConfigurationDto $configurations = null)
    {
        if (is_null($configurations) || (is_array($configurations) && empty($configurations))) {
            unset($this->Configurations);
        } else {
            $this->Configurations = $configurations;
        }
        return $this;
    }
    /**
     * Get Content 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 string|null
     */
    public function getContent()
    {
        return isset($this->Content) ? $this->Content : null;
    }
    /**
     * Set Content 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 string $content
     * @return \patest\StructType\CreatePaymentContextResponse
     */
    public function setContent($content = null)
    {
        // validation for constraint: string
        if (!is_null($content) && !is_string($content)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($content, true), gettype($content)), __LINE__);
        }
        if (is_null($content) || (is_array($content) && empty($content))) {
            unset($this->Content);
        } else {
            $this->Content = $content;
        }
        return $this;
    }
    /**
     * Get Resources 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\ArrayOfAssetResource|null
     */
    public function getResources()
    {
        return isset($this->Resources) ? $this->Resources : null;
    }
    /**
     * Set Resources 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\ArrayOfAssetResource $resources
     * @return \patest\StructType\CreatePaymentContextResponse
     */
    public function setResources(\patest\ArrayType\ArrayOfAssetResource $resources = null)
    {
        if (is_null($resources) || (is_array($resources) && empty($resources))) {
            unset($this->Resources);
        } else {
            $this->Resources = $resources;
        }
        return $this;
    }
}
