<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for TaxTypeSearchRowBasic StructType
 * @subpackage Structs
 */
class TaxTypeSearchRowBasic extends SearchRowBasic
{
    /**
     * The country
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnEnumSelectField[]
     */
    public $country;
    /**
     * The description
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnStringField[]
     */
    public $description;
    /**
     * The doesNotAddToTotal
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnBooleanField[]
     */
    public $doesNotAddToTotal;
    /**
     * The externalId
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnSelectField[]
     */
    public $externalId;
    /**
     * The internalId
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnSelectField[]
     */
    public $internalId;
    /**
     * The isInactive
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnBooleanField[]
     */
    public $isInactive;
    /**
     * The name
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnStringField[]
     */
    public $name;
    /**
     * The nexus
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnSelectField[]
     */
    public $nexus;
    /**
     * The payablesAccount
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnSelectField[]
     */
    public $payablesAccount;
    /**
     * The postToItemCost
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnBooleanField[]
     */
    public $postToItemCost;
    /**
     * The receivablesAccount
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnSelectField[]
     */
    public $receivablesAccount;
    /**
     * The reverseCharge
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnBooleanField[]
     */
    public $reverseCharge;
    /**
     * The taxInNetAmount
     * Meta information extracted from the WSDL
     * - maxOccurs: unbounded
     * - minOccurs: 0
     * @var \StructType\SearchColumnBooleanField[]
     */
    public $taxInNetAmount;
    /**
     * Constructor method for TaxTypeSearchRowBasic
     * @uses TaxTypeSearchRowBasic::setCountry()
     * @uses TaxTypeSearchRowBasic::setDescription()
     * @uses TaxTypeSearchRowBasic::setDoesNotAddToTotal()
     * @uses TaxTypeSearchRowBasic::setExternalId()
     * @uses TaxTypeSearchRowBasic::setInternalId()
     * @uses TaxTypeSearchRowBasic::setIsInactive()
     * @uses TaxTypeSearchRowBasic::setName()
     * @uses TaxTypeSearchRowBasic::setNexus()
     * @uses TaxTypeSearchRowBasic::setPayablesAccount()
     * @uses TaxTypeSearchRowBasic::setPostToItemCost()
     * @uses TaxTypeSearchRowBasic::setReceivablesAccount()
     * @uses TaxTypeSearchRowBasic::setReverseCharge()
     * @uses TaxTypeSearchRowBasic::setTaxInNetAmount()
     * @param \StructType\SearchColumnEnumSelectField[] $country
     * @param \StructType\SearchColumnStringField[] $description
     * @param \StructType\SearchColumnBooleanField[] $doesNotAddToTotal
     * @param \StructType\SearchColumnSelectField[] $externalId
     * @param \StructType\SearchColumnSelectField[] $internalId
     * @param \StructType\SearchColumnBooleanField[] $isInactive
     * @param \StructType\SearchColumnStringField[] $name
     * @param \StructType\SearchColumnSelectField[] $nexus
     * @param \StructType\SearchColumnSelectField[] $payablesAccount
     * @param \StructType\SearchColumnBooleanField[] $postToItemCost
     * @param \StructType\SearchColumnSelectField[] $receivablesAccount
     * @param \StructType\SearchColumnBooleanField[] $reverseCharge
     * @param \StructType\SearchColumnBooleanField[] $taxInNetAmount
     */
    public function __construct(array $country = array(), array $description = array(), array $doesNotAddToTotal = array(), array $externalId = array(), array $internalId = array(), array $isInactive = array(), array $name = array(), array $nexus = array(), array $payablesAccount = array(), array $postToItemCost = array(), array $receivablesAccount = array(), array $reverseCharge = array(), array $taxInNetAmount = array())
    {
        $this
            ->setCountry($country)
            ->setDescription($description)
            ->setDoesNotAddToTotal($doesNotAddToTotal)
            ->setExternalId($externalId)
            ->setInternalId($internalId)
            ->setIsInactive($isInactive)
            ->setName($name)
            ->setNexus($nexus)
            ->setPayablesAccount($payablesAccount)
            ->setPostToItemCost($postToItemCost)
            ->setReceivablesAccount($receivablesAccount)
            ->setReverseCharge($reverseCharge)
            ->setTaxInNetAmount($taxInNetAmount);
    }
    /**
     * Get country value
     * @return \StructType\SearchColumnEnumSelectField[]|null
     */
    public function getCountry()
    {
        return $this->country;
    }
    /**
     * This method is responsible for validating the values passed to the setCountry method
     * This method is willingly generated in order to preserve the one-line inline validation within the setCountry method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateCountryForArrayConstraintsFromSetCountry(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicCountryItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicCountryItem instanceof \StructType\SearchColumnEnumSelectField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicCountryItem) ? get_class($taxTypeSearchRowBasicCountryItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicCountryItem), var_export($taxTypeSearchRowBasicCountryItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The country property can only contain items of type \StructType\SearchColumnEnumSelectField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set country value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnEnumSelectField[] $country
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setCountry(array $country = array())
    {
        // validation for constraint: array
        if ('' !== ($countryArrayErrorMessage = self::validateCountryForArrayConstraintsFromSetCountry($country))) {
            throw new \InvalidArgumentException($countryArrayErrorMessage, __LINE__);
        }
        $this->country = $country;
        return $this;
    }
    /**
     * Add item to country value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnEnumSelectField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToCountry(\StructType\SearchColumnEnumSelectField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnEnumSelectField) {
            throw new \InvalidArgumentException(sprintf('The country property can only contain items of type \StructType\SearchColumnEnumSelectField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->country[] = $item;
        return $this;
    }
    /**
     * Get description value
     * @return \StructType\SearchColumnStringField[]|null
     */
    public function getDescription()
    {
        return $this->description;
    }
    /**
     * This method is responsible for validating the values passed to the setDescription method
     * This method is willingly generated in order to preserve the one-line inline validation within the setDescription method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateDescriptionForArrayConstraintsFromSetDescription(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicDescriptionItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicDescriptionItem instanceof \StructType\SearchColumnStringField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicDescriptionItem) ? get_class($taxTypeSearchRowBasicDescriptionItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicDescriptionItem), var_export($taxTypeSearchRowBasicDescriptionItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The description property can only contain items of type \StructType\SearchColumnStringField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set description value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnStringField[] $description
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setDescription(array $description = array())
    {
        // validation for constraint: array
        if ('' !== ($descriptionArrayErrorMessage = self::validateDescriptionForArrayConstraintsFromSetDescription($description))) {
            throw new \InvalidArgumentException($descriptionArrayErrorMessage, __LINE__);
        }
        $this->description = $description;
        return $this;
    }
    /**
     * Add item to description value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnStringField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToDescription(\StructType\SearchColumnStringField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnStringField) {
            throw new \InvalidArgumentException(sprintf('The description property can only contain items of type \StructType\SearchColumnStringField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->description[] = $item;
        return $this;
    }
    /**
     * Get doesNotAddToTotal value
     * @return \StructType\SearchColumnBooleanField[]|null
     */
    public function getDoesNotAddToTotal()
    {
        return $this->doesNotAddToTotal;
    }
    /**
     * This method is responsible for validating the values passed to the setDoesNotAddToTotal method
     * This method is willingly generated in order to preserve the one-line inline validation within the setDoesNotAddToTotal method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateDoesNotAddToTotalForArrayConstraintsFromSetDoesNotAddToTotal(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicDoesNotAddToTotalItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicDoesNotAddToTotalItem instanceof \StructType\SearchColumnBooleanField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicDoesNotAddToTotalItem) ? get_class($taxTypeSearchRowBasicDoesNotAddToTotalItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicDoesNotAddToTotalItem), var_export($taxTypeSearchRowBasicDoesNotAddToTotalItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The doesNotAddToTotal property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set doesNotAddToTotal value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField[] $doesNotAddToTotal
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setDoesNotAddToTotal(array $doesNotAddToTotal = array())
    {
        // validation for constraint: array
        if ('' !== ($doesNotAddToTotalArrayErrorMessage = self::validateDoesNotAddToTotalForArrayConstraintsFromSetDoesNotAddToTotal($doesNotAddToTotal))) {
            throw new \InvalidArgumentException($doesNotAddToTotalArrayErrorMessage, __LINE__);
        }
        $this->doesNotAddToTotal = $doesNotAddToTotal;
        return $this;
    }
    /**
     * Add item to doesNotAddToTotal value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToDoesNotAddToTotal(\StructType\SearchColumnBooleanField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnBooleanField) {
            throw new \InvalidArgumentException(sprintf('The doesNotAddToTotal property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->doesNotAddToTotal[] = $item;
        return $this;
    }
    /**
     * Get externalId value
     * @return \StructType\SearchColumnSelectField[]|null
     */
    public function getExternalId()
    {
        return $this->externalId;
    }
    /**
     * This method is responsible for validating the values passed to the setExternalId method
     * This method is willingly generated in order to preserve the one-line inline validation within the setExternalId method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateExternalIdForArrayConstraintsFromSetExternalId(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicExternalIdItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicExternalIdItem instanceof \StructType\SearchColumnSelectField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicExternalIdItem) ? get_class($taxTypeSearchRowBasicExternalIdItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicExternalIdItem), var_export($taxTypeSearchRowBasicExternalIdItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The externalId property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set externalId value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField[] $externalId
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setExternalId(array $externalId = array())
    {
        // validation for constraint: array
        if ('' !== ($externalIdArrayErrorMessage = self::validateExternalIdForArrayConstraintsFromSetExternalId($externalId))) {
            throw new \InvalidArgumentException($externalIdArrayErrorMessage, __LINE__);
        }
        $this->externalId = $externalId;
        return $this;
    }
    /**
     * Add item to externalId value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToExternalId(\StructType\SearchColumnSelectField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnSelectField) {
            throw new \InvalidArgumentException(sprintf('The externalId property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->externalId[] = $item;
        return $this;
    }
    /**
     * Get internalId value
     * @return \StructType\SearchColumnSelectField[]|null
     */
    public function getInternalId()
    {
        return $this->internalId;
    }
    /**
     * This method is responsible for validating the values passed to the setInternalId method
     * This method is willingly generated in order to preserve the one-line inline validation within the setInternalId method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateInternalIdForArrayConstraintsFromSetInternalId(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicInternalIdItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicInternalIdItem instanceof \StructType\SearchColumnSelectField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicInternalIdItem) ? get_class($taxTypeSearchRowBasicInternalIdItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicInternalIdItem), var_export($taxTypeSearchRowBasicInternalIdItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The internalId property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set internalId value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField[] $internalId
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setInternalId(array $internalId = array())
    {
        // validation for constraint: array
        if ('' !== ($internalIdArrayErrorMessage = self::validateInternalIdForArrayConstraintsFromSetInternalId($internalId))) {
            throw new \InvalidArgumentException($internalIdArrayErrorMessage, __LINE__);
        }
        $this->internalId = $internalId;
        return $this;
    }
    /**
     * Add item to internalId value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToInternalId(\StructType\SearchColumnSelectField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnSelectField) {
            throw new \InvalidArgumentException(sprintf('The internalId property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->internalId[] = $item;
        return $this;
    }
    /**
     * Get isInactive value
     * @return \StructType\SearchColumnBooleanField[]|null
     */
    public function getIsInactive()
    {
        return $this->isInactive;
    }
    /**
     * This method is responsible for validating the values passed to the setIsInactive method
     * This method is willingly generated in order to preserve the one-line inline validation within the setIsInactive method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateIsInactiveForArrayConstraintsFromSetIsInactive(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicIsInactiveItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicIsInactiveItem instanceof \StructType\SearchColumnBooleanField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicIsInactiveItem) ? get_class($taxTypeSearchRowBasicIsInactiveItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicIsInactiveItem), var_export($taxTypeSearchRowBasicIsInactiveItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The isInactive property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set isInactive value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField[] $isInactive
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setIsInactive(array $isInactive = array())
    {
        // validation for constraint: array
        if ('' !== ($isInactiveArrayErrorMessage = self::validateIsInactiveForArrayConstraintsFromSetIsInactive($isInactive))) {
            throw new \InvalidArgumentException($isInactiveArrayErrorMessage, __LINE__);
        }
        $this->isInactive = $isInactive;
        return $this;
    }
    /**
     * Add item to isInactive value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToIsInactive(\StructType\SearchColumnBooleanField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnBooleanField) {
            throw new \InvalidArgumentException(sprintf('The isInactive property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->isInactive[] = $item;
        return $this;
    }
    /**
     * Get name value
     * @return \StructType\SearchColumnStringField[]|null
     */
    public function getName()
    {
        return $this->name;
    }
    /**
     * This method is responsible for validating the values passed to the setName method
     * This method is willingly generated in order to preserve the one-line inline validation within the setName method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateNameForArrayConstraintsFromSetName(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicNameItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicNameItem instanceof \StructType\SearchColumnStringField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicNameItem) ? get_class($taxTypeSearchRowBasicNameItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicNameItem), var_export($taxTypeSearchRowBasicNameItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The name property can only contain items of type \StructType\SearchColumnStringField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set name value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnStringField[] $name
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setName(array $name = array())
    {
        // validation for constraint: array
        if ('' !== ($nameArrayErrorMessage = self::validateNameForArrayConstraintsFromSetName($name))) {
            throw new \InvalidArgumentException($nameArrayErrorMessage, __LINE__);
        }
        $this->name = $name;
        return $this;
    }
    /**
     * Add item to name value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnStringField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToName(\StructType\SearchColumnStringField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnStringField) {
            throw new \InvalidArgumentException(sprintf('The name property can only contain items of type \StructType\SearchColumnStringField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->name[] = $item;
        return $this;
    }
    /**
     * Get nexus value
     * @return \StructType\SearchColumnSelectField[]|null
     */
    public function getNexus()
    {
        return $this->nexus;
    }
    /**
     * This method is responsible for validating the values passed to the setNexus method
     * This method is willingly generated in order to preserve the one-line inline validation within the setNexus method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateNexusForArrayConstraintsFromSetNexus(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicNexusItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicNexusItem instanceof \StructType\SearchColumnSelectField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicNexusItem) ? get_class($taxTypeSearchRowBasicNexusItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicNexusItem), var_export($taxTypeSearchRowBasicNexusItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The nexus property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set nexus value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField[] $nexus
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setNexus(array $nexus = array())
    {
        // validation for constraint: array
        if ('' !== ($nexusArrayErrorMessage = self::validateNexusForArrayConstraintsFromSetNexus($nexus))) {
            throw new \InvalidArgumentException($nexusArrayErrorMessage, __LINE__);
        }
        $this->nexus = $nexus;
        return $this;
    }
    /**
     * Add item to nexus value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToNexus(\StructType\SearchColumnSelectField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnSelectField) {
            throw new \InvalidArgumentException(sprintf('The nexus property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->nexus[] = $item;
        return $this;
    }
    /**
     * Get payablesAccount value
     * @return \StructType\SearchColumnSelectField[]|null
     */
    public function getPayablesAccount()
    {
        return $this->payablesAccount;
    }
    /**
     * This method is responsible for validating the values passed to the setPayablesAccount method
     * This method is willingly generated in order to preserve the one-line inline validation within the setPayablesAccount method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validatePayablesAccountForArrayConstraintsFromSetPayablesAccount(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicPayablesAccountItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicPayablesAccountItem instanceof \StructType\SearchColumnSelectField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicPayablesAccountItem) ? get_class($taxTypeSearchRowBasicPayablesAccountItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicPayablesAccountItem), var_export($taxTypeSearchRowBasicPayablesAccountItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The payablesAccount property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set payablesAccount value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField[] $payablesAccount
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setPayablesAccount(array $payablesAccount = array())
    {
        // validation for constraint: array
        if ('' !== ($payablesAccountArrayErrorMessage = self::validatePayablesAccountForArrayConstraintsFromSetPayablesAccount($payablesAccount))) {
            throw new \InvalidArgumentException($payablesAccountArrayErrorMessage, __LINE__);
        }
        $this->payablesAccount = $payablesAccount;
        return $this;
    }
    /**
     * Add item to payablesAccount value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToPayablesAccount(\StructType\SearchColumnSelectField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnSelectField) {
            throw new \InvalidArgumentException(sprintf('The payablesAccount property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->payablesAccount[] = $item;
        return $this;
    }
    /**
     * Get postToItemCost value
     * @return \StructType\SearchColumnBooleanField[]|null
     */
    public function getPostToItemCost()
    {
        return $this->postToItemCost;
    }
    /**
     * This method is responsible for validating the values passed to the setPostToItemCost method
     * This method is willingly generated in order to preserve the one-line inline validation within the setPostToItemCost method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validatePostToItemCostForArrayConstraintsFromSetPostToItemCost(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicPostToItemCostItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicPostToItemCostItem instanceof \StructType\SearchColumnBooleanField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicPostToItemCostItem) ? get_class($taxTypeSearchRowBasicPostToItemCostItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicPostToItemCostItem), var_export($taxTypeSearchRowBasicPostToItemCostItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The postToItemCost property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set postToItemCost value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField[] $postToItemCost
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setPostToItemCost(array $postToItemCost = array())
    {
        // validation for constraint: array
        if ('' !== ($postToItemCostArrayErrorMessage = self::validatePostToItemCostForArrayConstraintsFromSetPostToItemCost($postToItemCost))) {
            throw new \InvalidArgumentException($postToItemCostArrayErrorMessage, __LINE__);
        }
        $this->postToItemCost = $postToItemCost;
        return $this;
    }
    /**
     * Add item to postToItemCost value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToPostToItemCost(\StructType\SearchColumnBooleanField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnBooleanField) {
            throw new \InvalidArgumentException(sprintf('The postToItemCost property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->postToItemCost[] = $item;
        return $this;
    }
    /**
     * Get receivablesAccount value
     * @return \StructType\SearchColumnSelectField[]|null
     */
    public function getReceivablesAccount()
    {
        return $this->receivablesAccount;
    }
    /**
     * This method is responsible for validating the values passed to the setReceivablesAccount method
     * This method is willingly generated in order to preserve the one-line inline validation within the setReceivablesAccount method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateReceivablesAccountForArrayConstraintsFromSetReceivablesAccount(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicReceivablesAccountItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicReceivablesAccountItem instanceof \StructType\SearchColumnSelectField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicReceivablesAccountItem) ? get_class($taxTypeSearchRowBasicReceivablesAccountItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicReceivablesAccountItem), var_export($taxTypeSearchRowBasicReceivablesAccountItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The receivablesAccount property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set receivablesAccount value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField[] $receivablesAccount
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setReceivablesAccount(array $receivablesAccount = array())
    {
        // validation for constraint: array
        if ('' !== ($receivablesAccountArrayErrorMessage = self::validateReceivablesAccountForArrayConstraintsFromSetReceivablesAccount($receivablesAccount))) {
            throw new \InvalidArgumentException($receivablesAccountArrayErrorMessage, __LINE__);
        }
        $this->receivablesAccount = $receivablesAccount;
        return $this;
    }
    /**
     * Add item to receivablesAccount value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnSelectField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToReceivablesAccount(\StructType\SearchColumnSelectField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnSelectField) {
            throw new \InvalidArgumentException(sprintf('The receivablesAccount property can only contain items of type \StructType\SearchColumnSelectField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->receivablesAccount[] = $item;
        return $this;
    }
    /**
     * Get reverseCharge value
     * @return \StructType\SearchColumnBooleanField[]|null
     */
    public function getReverseCharge()
    {
        return $this->reverseCharge;
    }
    /**
     * This method is responsible for validating the values passed to the setReverseCharge method
     * This method is willingly generated in order to preserve the one-line inline validation within the setReverseCharge method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateReverseChargeForArrayConstraintsFromSetReverseCharge(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicReverseChargeItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicReverseChargeItem instanceof \StructType\SearchColumnBooleanField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicReverseChargeItem) ? get_class($taxTypeSearchRowBasicReverseChargeItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicReverseChargeItem), var_export($taxTypeSearchRowBasicReverseChargeItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The reverseCharge property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set reverseCharge value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField[] $reverseCharge
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setReverseCharge(array $reverseCharge = array())
    {
        // validation for constraint: array
        if ('' !== ($reverseChargeArrayErrorMessage = self::validateReverseChargeForArrayConstraintsFromSetReverseCharge($reverseCharge))) {
            throw new \InvalidArgumentException($reverseChargeArrayErrorMessage, __LINE__);
        }
        $this->reverseCharge = $reverseCharge;
        return $this;
    }
    /**
     * Add item to reverseCharge value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToReverseCharge(\StructType\SearchColumnBooleanField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnBooleanField) {
            throw new \InvalidArgumentException(sprintf('The reverseCharge property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->reverseCharge[] = $item;
        return $this;
    }
    /**
     * Get taxInNetAmount value
     * @return \StructType\SearchColumnBooleanField[]|null
     */
    public function getTaxInNetAmount()
    {
        return $this->taxInNetAmount;
    }
    /**
     * This method is responsible for validating the values passed to the setTaxInNetAmount method
     * This method is willingly generated in order to preserve the one-line inline validation within the setTaxInNetAmount method
     * @param array $values
     * @return string A non-empty message if the values does not match the validation rules
     */
    public static function validateTaxInNetAmountForArrayConstraintsFromSetTaxInNetAmount(array $values = array())
    {
        $message = '';
        $invalidValues = [];
        foreach ($values as $taxTypeSearchRowBasicTaxInNetAmountItem) {
            // validation for constraint: itemType
            if (!$taxTypeSearchRowBasicTaxInNetAmountItem instanceof \StructType\SearchColumnBooleanField) {
                $invalidValues[] = is_object($taxTypeSearchRowBasicTaxInNetAmountItem) ? get_class($taxTypeSearchRowBasicTaxInNetAmountItem) : sprintf('%s(%s)', gettype($taxTypeSearchRowBasicTaxInNetAmountItem), var_export($taxTypeSearchRowBasicTaxInNetAmountItem, true));
            }
        }
        if (!empty($invalidValues)) {
            $message = sprintf('The taxInNetAmount property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($invalidValues) ? get_class($invalidValues) : (is_array($invalidValues) ? implode(', ', $invalidValues) : gettype($invalidValues)));
        }
        unset($invalidValues);
        return $message;
    }
    /**
     * Set taxInNetAmount value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField[] $taxInNetAmount
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function setTaxInNetAmount(array $taxInNetAmount = array())
    {
        // validation for constraint: array
        if ('' !== ($taxInNetAmountArrayErrorMessage = self::validateTaxInNetAmountForArrayConstraintsFromSetTaxInNetAmount($taxInNetAmount))) {
            throw new \InvalidArgumentException($taxInNetAmountArrayErrorMessage, __LINE__);
        }
        $this->taxInNetAmount = $taxInNetAmount;
        return $this;
    }
    /**
     * Add item to taxInNetAmount value
     * @throws \InvalidArgumentException
     * @param \StructType\SearchColumnBooleanField $item
     * @return \StructType\TaxTypeSearchRowBasic
     */
    public function addToTaxInNetAmount(\StructType\SearchColumnBooleanField $item)
    {
        // validation for constraint: itemType
        if (!$item instanceof \StructType\SearchColumnBooleanField) {
            throw new \InvalidArgumentException(sprintf('The taxInNetAmount property can only contain items of type \StructType\SearchColumnBooleanField, %s given', is_object($item) ? get_class($item) : (is_array($item) ? implode(', ', $item) : gettype($item))), __LINE__);
        }
        $this->taxInNetAmount[] = $item;
        return $this;
    }
}
