<?php

namespace patest\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for Printing.PrintableItem.InvoiceItemsGroupRecord StructType
 * @subpackage Structs
 */
class Printing_PrintableItem_InvoiceItemsGroupRecord extends Printing_PrintableItem_Base
{
    /**
     * The AmountPerItem
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\Money
     */
    public $AmountPerItem;
    /**
     * The Details
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\Printing_PrintableItem_AccountingDocumentItemDetails
     */
    public $Details;
    /**
     * The ItemType
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var int
     */
    public $ItemType;
    /**
     * The PriceTypeDetails
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $PriceTypeDetails;
    /**
     * The Quantity
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var int
     */
    public $Quantity;
    /**
     * The TotalAmount
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\Money
     */
    public $TotalAmount;
    /**
     * The TotalAmountNeto
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\Money
     */
    public $TotalAmountNeto;
    /**
     * The TotalInsideCommissionAmount
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\Money
     */
    public $TotalInsideCommissionAmount;
    /**
     * The TotalInsuranceAmount
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\Money
     */
    public $TotalInsuranceAmount;
    /**
     * The TotalVatAmount
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \patest\StructType\Money
     */
    public $TotalVatAmount;
    /**
     * The TransactionNumber
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var int
     */
    public $TransactionNumber;
    /**
     * Constructor method for Printing.PrintableItem.InvoiceItemsGroupRecord
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setAmountPerItem()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setDetails()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setItemType()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setPriceTypeDetails()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setQuantity()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setTotalAmount()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setTotalAmountNeto()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setTotalInsideCommissionAmount()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setTotalInsuranceAmount()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setTotalVatAmount()
     * @uses Printing_PrintableItem_InvoiceItemsGroupRecord::setTransactionNumber()
     * @param \patest\StructType\Money $amountPerItem
     * @param \patest\StructType\Printing_PrintableItem_AccountingDocumentItemDetails $details
     * @param int $itemType
     * @param string $priceTypeDetails
     * @param int $quantity
     * @param \patest\StructType\Money $totalAmount
     * @param \patest\StructType\Money $totalAmountNeto
     * @param \patest\StructType\Money $totalInsideCommissionAmount
     * @param \patest\StructType\Money $totalInsuranceAmount
     * @param \patest\StructType\Money $totalVatAmount
     * @param int $transactionNumber
     */
    public function __construct(\patest\StructType\Money $amountPerItem = null, \patest\StructType\Printing_PrintableItem_AccountingDocumentItemDetails $details = null, $itemType = null, $priceTypeDetails = null, $quantity = null, \patest\StructType\Money $totalAmount = null, \patest\StructType\Money $totalAmountNeto = null, \patest\StructType\Money $totalInsideCommissionAmount = null, \patest\StructType\Money $totalInsuranceAmount = null, \patest\StructType\Money $totalVatAmount = null, $transactionNumber = null)
    {
        $this
            ->setAmountPerItem($amountPerItem)
            ->setDetails($details)
            ->setItemType($itemType)
            ->setPriceTypeDetails($priceTypeDetails)
            ->setQuantity($quantity)
            ->setTotalAmount($totalAmount)
            ->setTotalAmountNeto($totalAmountNeto)
            ->setTotalInsideCommissionAmount($totalInsideCommissionAmount)
            ->setTotalInsuranceAmount($totalInsuranceAmount)
            ->setTotalVatAmount($totalVatAmount)
            ->setTransactionNumber($transactionNumber);
    }
    /**
     * Get AmountPerItem 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 getAmountPerItem()
    {
        return isset($this->AmountPerItem) ? $this->AmountPerItem : null;
    }
    /**
     * Set AmountPerItem 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 $amountPerItem
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setAmountPerItem(\patest\StructType\Money $amountPerItem = null)
    {
        if (is_null($amountPerItem) || (is_array($amountPerItem) && empty($amountPerItem))) {
            unset($this->AmountPerItem);
        } else {
            $this->AmountPerItem = $amountPerItem;
        }
        return $this;
    }
    /**
     * Get Details 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\Printing_PrintableItem_AccountingDocumentItemDetails|null
     */
    public function getDetails()
    {
        return isset($this->Details) ? $this->Details : null;
    }
    /**
     * Set Details 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\Printing_PrintableItem_AccountingDocumentItemDetails $details
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setDetails(\patest\StructType\Printing_PrintableItem_AccountingDocumentItemDetails $details = null)
    {
        if (is_null($details) || (is_array($details) && empty($details))) {
            unset($this->Details);
        } else {
            $this->Details = $details;
        }
        return $this;
    }
    /**
     * Get ItemType 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 int|null
     */
    public function getItemType()
    {
        return isset($this->ItemType) ? $this->ItemType : null;
    }
    /**
     * Set ItemType 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 int $itemType
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setItemType($itemType = null)
    {
        // validation for constraint: int
        if (!is_null($itemType) && !(is_int($itemType) || ctype_digit($itemType))) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide an integer value, %s given', var_export($itemType, true), gettype($itemType)), __LINE__);
        }
        if (is_null($itemType) || (is_array($itemType) && empty($itemType))) {
            unset($this->ItemType);
        } else {
            $this->ItemType = $itemType;
        }
        return $this;
    }
    /**
     * Get PriceTypeDetails 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 getPriceTypeDetails()
    {
        return isset($this->PriceTypeDetails) ? $this->PriceTypeDetails : null;
    }
    /**
     * Set PriceTypeDetails 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 $priceTypeDetails
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setPriceTypeDetails($priceTypeDetails = null)
    {
        // validation for constraint: string
        if (!is_null($priceTypeDetails) && !is_string($priceTypeDetails)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($priceTypeDetails, true), gettype($priceTypeDetails)), __LINE__);
        }
        if (is_null($priceTypeDetails) || (is_array($priceTypeDetails) && empty($priceTypeDetails))) {
            unset($this->PriceTypeDetails);
        } else {
            $this->PriceTypeDetails = $priceTypeDetails;
        }
        return $this;
    }
    /**
     * Get Quantity 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 int|null
     */
    public function getQuantity()
    {
        return isset($this->Quantity) ? $this->Quantity : null;
    }
    /**
     * Set Quantity 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 int $quantity
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setQuantity($quantity = null)
    {
        // validation for constraint: int
        if (!is_null($quantity) && !(is_int($quantity) || ctype_digit($quantity))) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide an integer value, %s given', var_export($quantity, true), gettype($quantity)), __LINE__);
        }
        if (is_null($quantity) || (is_array($quantity) && empty($quantity))) {
            unset($this->Quantity);
        } else {
            $this->Quantity = $quantity;
        }
        return $this;
    }
    /**
     * Get TotalAmount 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 getTotalAmount()
    {
        return isset($this->TotalAmount) ? $this->TotalAmount : null;
    }
    /**
     * Set TotalAmount 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 $totalAmount
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setTotalAmount(\patest\StructType\Money $totalAmount = null)
    {
        if (is_null($totalAmount) || (is_array($totalAmount) && empty($totalAmount))) {
            unset($this->TotalAmount);
        } else {
            $this->TotalAmount = $totalAmount;
        }
        return $this;
    }
    /**
     * Get TotalAmountNeto 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 getTotalAmountNeto()
    {
        return isset($this->TotalAmountNeto) ? $this->TotalAmountNeto : null;
    }
    /**
     * Set TotalAmountNeto 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 $totalAmountNeto
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setTotalAmountNeto(\patest\StructType\Money $totalAmountNeto = null)
    {
        if (is_null($totalAmountNeto) || (is_array($totalAmountNeto) && empty($totalAmountNeto))) {
            unset($this->TotalAmountNeto);
        } else {
            $this->TotalAmountNeto = $totalAmountNeto;
        }
        return $this;
    }
    /**
     * Get TotalInsideCommissionAmount 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 getTotalInsideCommissionAmount()
    {
        return isset($this->TotalInsideCommissionAmount) ? $this->TotalInsideCommissionAmount : null;
    }
    /**
     * Set TotalInsideCommissionAmount 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 $totalInsideCommissionAmount
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setTotalInsideCommissionAmount(\patest\StructType\Money $totalInsideCommissionAmount = null)
    {
        if (is_null($totalInsideCommissionAmount) || (is_array($totalInsideCommissionAmount) && empty($totalInsideCommissionAmount))) {
            unset($this->TotalInsideCommissionAmount);
        } else {
            $this->TotalInsideCommissionAmount = $totalInsideCommissionAmount;
        }
        return $this;
    }
    /**
     * Get TotalInsuranceAmount 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 getTotalInsuranceAmount()
    {
        return isset($this->TotalInsuranceAmount) ? $this->TotalInsuranceAmount : null;
    }
    /**
     * Set TotalInsuranceAmount 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 $totalInsuranceAmount
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setTotalInsuranceAmount(\patest\StructType\Money $totalInsuranceAmount = null)
    {
        if (is_null($totalInsuranceAmount) || (is_array($totalInsuranceAmount) && empty($totalInsuranceAmount))) {
            unset($this->TotalInsuranceAmount);
        } else {
            $this->TotalInsuranceAmount = $totalInsuranceAmount;
        }
        return $this;
    }
    /**
     * Get TotalVatAmount 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 getTotalVatAmount()
    {
        return isset($this->TotalVatAmount) ? $this->TotalVatAmount : null;
    }
    /**
     * Set TotalVatAmount 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 $totalVatAmount
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setTotalVatAmount(\patest\StructType\Money $totalVatAmount = null)
    {
        if (is_null($totalVatAmount) || (is_array($totalVatAmount) && empty($totalVatAmount))) {
            unset($this->TotalVatAmount);
        } else {
            $this->TotalVatAmount = $totalVatAmount;
        }
        return $this;
    }
    /**
     * Get TransactionNumber 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 int|null
     */
    public function getTransactionNumber()
    {
        return isset($this->TransactionNumber) ? $this->TransactionNumber : null;
    }
    /**
     * Set TransactionNumber 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 int $transactionNumber
     * @return \patest\StructType\Printing_PrintableItem_InvoiceItemsGroupRecord
     */
    public function setTransactionNumber($transactionNumber = null)
    {
        // validation for constraint: int
        if (!is_null($transactionNumber) && !(is_int($transactionNumber) || ctype_digit($transactionNumber))) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide an integer value, %s given', var_export($transactionNumber, true), gettype($transactionNumber)), __LINE__);
        }
        if (is_null($transactionNumber) || (is_array($transactionNumber) && empty($transactionNumber))) {
            unset($this->TransactionNumber);
        } else {
            $this->TransactionNumber = $transactionNumber;
        }
        return $this;
    }
}
