<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for Cancel_Internal_Service_Delivery_RequestType StructType
 * Meta information extracted from the WSDL
 * - documentation: Start element for canceling an Internal Service Delivery.
 * @subpackage Structs
 */
class Cancel_Internal_Service_Delivery_RequestType extends AbstractStructBase
{
    /**
     * The Internal_Service_Delivery_Reference
     * Meta information extracted from the WSDL
     * - documentation: Reference to the Internal Service Delivery being canceled.
     * - minOccurs: 0
     * @var \StructType\Internal_Service_DeliveryObjectType
     */
    public $Internal_Service_Delivery_Reference;
    /**
     * The Internal_Service_Delivery_Data
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * @var \StructType\Cancel_Internal_Service_Delivery_DataType
     */
    public $Internal_Service_Delivery_Data;
    /**
     * The version
     * Meta information extracted from the WSDL
     * - ref: wd:version
     * @var string
     */
    public $version;
    /**
     * Constructor method for Cancel_Internal_Service_Delivery_RequestType
     * @uses Cancel_Internal_Service_Delivery_RequestType::setInternal_Service_Delivery_Reference()
     * @uses Cancel_Internal_Service_Delivery_RequestType::setInternal_Service_Delivery_Data()
     * @uses Cancel_Internal_Service_Delivery_RequestType::setVersion()
     * @param \StructType\Internal_Service_DeliveryObjectType $internal_Service_Delivery_Reference
     * @param \StructType\Cancel_Internal_Service_Delivery_DataType $internal_Service_Delivery_Data
     * @param string $version
     */
    public function __construct(\StructType\Internal_Service_DeliveryObjectType $internal_Service_Delivery_Reference = null, \StructType\Cancel_Internal_Service_Delivery_DataType $internal_Service_Delivery_Data = null, $version = null)
    {
        $this
            ->setInternal_Service_Delivery_Reference($internal_Service_Delivery_Reference)
            ->setInternal_Service_Delivery_Data($internal_Service_Delivery_Data)
            ->setVersion($version);
    }
    /**
     * Get Internal_Service_Delivery_Reference value
     * @return \StructType\Internal_Service_DeliveryObjectType|null
     */
    public function getInternal_Service_Delivery_Reference()
    {
        return $this->Internal_Service_Delivery_Reference;
    }
    /**
     * Set Internal_Service_Delivery_Reference value
     * @param \StructType\Internal_Service_DeliveryObjectType $internal_Service_Delivery_Reference
     * @return \StructType\Cancel_Internal_Service_Delivery_RequestType
     */
    public function setInternal_Service_Delivery_Reference(\StructType\Internal_Service_DeliveryObjectType $internal_Service_Delivery_Reference = null)
    {
        $this->Internal_Service_Delivery_Reference = $internal_Service_Delivery_Reference;
        return $this;
    }
    /**
     * Get Internal_Service_Delivery_Data value
     * @return \StructType\Cancel_Internal_Service_Delivery_DataType|null
     */
    public function getInternal_Service_Delivery_Data()
    {
        return $this->Internal_Service_Delivery_Data;
    }
    /**
     * Set Internal_Service_Delivery_Data value
     * @param \StructType\Cancel_Internal_Service_Delivery_DataType $internal_Service_Delivery_Data
     * @return \StructType\Cancel_Internal_Service_Delivery_RequestType
     */
    public function setInternal_Service_Delivery_Data(\StructType\Cancel_Internal_Service_Delivery_DataType $internal_Service_Delivery_Data = null)
    {
        $this->Internal_Service_Delivery_Data = $internal_Service_Delivery_Data;
        return $this;
    }
    /**
     * Get version value
     * @return string|null
     */
    public function getVersion()
    {
        return $this->version;
    }
    /**
     * Set version value
     * @param string $version
     * @return \StructType\Cancel_Internal_Service_Delivery_RequestType
     */
    public function setVersion($version = null)
    {
        // validation for constraint: string
        if (!is_null($version) && !is_string($version)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($version, true), gettype($version)), __LINE__);
        }
        $this->version = $version;
        return $this;
    }
}
