<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for Put_External_Business_Entity_Contact_ResponseType
 * StructType
 * Meta information extracted from the WSDL
 * - documentation: Element containing Put External Business Entity Contact Response Data
 * @subpackage Structs
 */
class Put_External_Business_Entity_Contact_ResponseType extends AbstractStructBase
{
    /**
     * The External_Business_Entity_Contact_Reference
     * Meta information extracted from the WSDL
     * - documentation: Reference to an existing External Business Entity Contact
     * - minOccurs: 0
     * @var \StructType\Business_Entity_ContactObjectType
     */
    public $External_Business_Entity_Contact_Reference;
    /**
     * The version
     * Meta information extracted from the WSDL
     * - ref: wd:version
     * @var string
     */
    public $version;
    /**
     * Constructor method for Put_External_Business_Entity_Contact_ResponseType
     * @uses Put_External_Business_Entity_Contact_ResponseType::setExternal_Business_Entity_Contact_Reference()
     * @uses Put_External_Business_Entity_Contact_ResponseType::setVersion()
     * @param \StructType\Business_Entity_ContactObjectType $external_Business_Entity_Contact_Reference
     * @param string $version
     */
    public function __construct(\StructType\Business_Entity_ContactObjectType $external_Business_Entity_Contact_Reference = null, $version = null)
    {
        $this
            ->setExternal_Business_Entity_Contact_Reference($external_Business_Entity_Contact_Reference)
            ->setVersion($version);
    }
    /**
     * Get External_Business_Entity_Contact_Reference value
     * @return \StructType\Business_Entity_ContactObjectType|null
     */
    public function getExternal_Business_Entity_Contact_Reference()
    {
        return $this->External_Business_Entity_Contact_Reference;
    }
    /**
     * Set External_Business_Entity_Contact_Reference value
     * @param \StructType\Business_Entity_ContactObjectType $external_Business_Entity_Contact_Reference
     * @return \StructType\Put_External_Business_Entity_Contact_ResponseType
     */
    public function setExternal_Business_Entity_Contact_Reference(\StructType\Business_Entity_ContactObjectType $external_Business_Entity_Contact_Reference = null)
    {
        $this->External_Business_Entity_Contact_Reference = $external_Business_Entity_Contact_Reference;
        return $this;
    }
    /**
     * Get version value
     * @return string|null
     */
    public function getVersion()
    {
        return $this->version;
    }
    /**
     * Set version value
     * @param string $version
     * @return \StructType\Put_External_Business_Entity_Contact_ResponseType
     */
    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;
    }
}
