<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for JP_ExternalInfo StructType
 * @subpackage Structs
 */
class JP_ExternalInfo extends AbstractStructBase
{
    /**
     * The Supplier
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \StructType\JP_Supplier
     */
    public $Supplier;
    /**
     * The ExternalLocator
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var string
     */
    public $ExternalLocator;
    /**
     * The ExternalCancellationLocator
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var string
     */
    public $ExternalCancellationLocator;
    /**
     * The ExternalTransactionIDS
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \ArrayType\ArrayOfJP_ExternalTransactionID
     */
    public $ExternalTransactionIDS;
    /**
     * The HotelConfirmationNumber
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var string
     */
    public $HotelConfirmationNumber;
    /**
     * The HotelCommunication
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var \StructType\JP_HotelCommunication
     */
    public $HotelCommunication;
    /**
     * Constructor method for JP_ExternalInfo
     * @uses JP_ExternalInfo::setSupplier()
     * @uses JP_ExternalInfo::setExternalLocator()
     * @uses JP_ExternalInfo::setExternalCancellationLocator()
     * @uses JP_ExternalInfo::setExternalTransactionIDS()
     * @uses JP_ExternalInfo::setHotelConfirmationNumber()
     * @uses JP_ExternalInfo::setHotelCommunication()
     * @param \StructType\JP_Supplier $supplier
     * @param string $externalLocator
     * @param string $externalCancellationLocator
     * @param \ArrayType\ArrayOfJP_ExternalTransactionID $externalTransactionIDS
     * @param string $hotelConfirmationNumber
     * @param \StructType\JP_HotelCommunication $hotelCommunication
     */
    public function __construct(\StructType\JP_Supplier $supplier = null, $externalLocator = null, $externalCancellationLocator = null, \ArrayType\ArrayOfJP_ExternalTransactionID $externalTransactionIDS = null, $hotelConfirmationNumber = null, \StructType\JP_HotelCommunication $hotelCommunication = null)
    {
        $this
            ->setSupplier($supplier)
            ->setExternalLocator($externalLocator)
            ->setExternalCancellationLocator($externalCancellationLocator)
            ->setExternalTransactionIDS($externalTransactionIDS)
            ->setHotelConfirmationNumber($hotelConfirmationNumber)
            ->setHotelCommunication($hotelCommunication);
    }
    /**
     * Get Supplier value
     * @return \StructType\JP_Supplier|null
     */
    public function getSupplier()
    {
        return $this->Supplier;
    }
    /**
     * Set Supplier value
     * @param \StructType\JP_Supplier $supplier
     * @return \StructType\JP_ExternalInfo
     */
    public function setSupplier(\StructType\JP_Supplier $supplier = null)
    {
        $this->Supplier = $supplier;
        return $this;
    }
    /**
     * Get ExternalLocator value
     * @return string|null
     */
    public function getExternalLocator()
    {
        return $this->ExternalLocator;
    }
    /**
     * Set ExternalLocator value
     * @param string $externalLocator
     * @return \StructType\JP_ExternalInfo
     */
    public function setExternalLocator($externalLocator = null)
    {
        // validation for constraint: string
        if (!is_null($externalLocator) && !is_string($externalLocator)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($externalLocator, true), gettype($externalLocator)), __LINE__);
        }
        $this->ExternalLocator = $externalLocator;
        return $this;
    }
    /**
     * Get ExternalCancellationLocator value
     * @return string|null
     */
    public function getExternalCancellationLocator()
    {
        return $this->ExternalCancellationLocator;
    }
    /**
     * Set ExternalCancellationLocator value
     * @param string $externalCancellationLocator
     * @return \StructType\JP_ExternalInfo
     */
    public function setExternalCancellationLocator($externalCancellationLocator = null)
    {
        // validation for constraint: string
        if (!is_null($externalCancellationLocator) && !is_string($externalCancellationLocator)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($externalCancellationLocator, true), gettype($externalCancellationLocator)), __LINE__);
        }
        $this->ExternalCancellationLocator = $externalCancellationLocator;
        return $this;
    }
    /**
     * Get ExternalTransactionIDS value
     * @return \ArrayType\ArrayOfJP_ExternalTransactionID|null
     */
    public function getExternalTransactionIDS()
    {
        return $this->ExternalTransactionIDS;
    }
    /**
     * Set ExternalTransactionIDS value
     * @param \ArrayType\ArrayOfJP_ExternalTransactionID $externalTransactionIDS
     * @return \StructType\JP_ExternalInfo
     */
    public function setExternalTransactionIDS(\ArrayType\ArrayOfJP_ExternalTransactionID $externalTransactionIDS = null)
    {
        $this->ExternalTransactionIDS = $externalTransactionIDS;
        return $this;
    }
    /**
     * Get HotelConfirmationNumber value
     * @return string|null
     */
    public function getHotelConfirmationNumber()
    {
        return $this->HotelConfirmationNumber;
    }
    /**
     * Set HotelConfirmationNumber value
     * @param string $hotelConfirmationNumber
     * @return \StructType\JP_ExternalInfo
     */
    public function setHotelConfirmationNumber($hotelConfirmationNumber = null)
    {
        // validation for constraint: string
        if (!is_null($hotelConfirmationNumber) && !is_string($hotelConfirmationNumber)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($hotelConfirmationNumber, true), gettype($hotelConfirmationNumber)), __LINE__);
        }
        $this->HotelConfirmationNumber = $hotelConfirmationNumber;
        return $this;
    }
    /**
     * Get HotelCommunication value
     * @return \StructType\JP_HotelCommunication|null
     */
    public function getHotelCommunication()
    {
        return $this->HotelCommunication;
    }
    /**
     * Set HotelCommunication value
     * @param \StructType\JP_HotelCommunication $hotelCommunication
     * @return \StructType\JP_ExternalInfo
     */
    public function setHotelCommunication(\StructType\JP_HotelCommunication $hotelCommunication = null)
    {
        $this->HotelCommunication = $hotelCommunication;
        return $this;
    }
}
