<?php

namespace EuVies;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for checkVat StructType
 * @subpackage Structs
 */
class CheckVat extends AbstractStructBase
{
    /**
     * The countryCode
     * @var string
     */
    public $countryCode;
    /**
     * The vatNumber
     * @var string
     */
    public $vatNumber;
    /**
     * Constructor method for checkVat
     * @uses CheckVat::setCountryCode()
     * @uses CheckVat::setVatNumber()
     * @param string $countryCode
     * @param string $vatNumber
     */
    public function __construct($countryCode = null, $vatNumber = null)
    {
        $this
            ->setCountryCode($countryCode)
            ->setVatNumber($vatNumber);
    }
    /**
     * Get countryCode value
     * @return string|null
     */
    public function getCountryCode()
    {
        return $this->countryCode;
    }
    /**
     * Set countryCode value
     * @param string $countryCode
     * @return \EuVies\CheckVat
     */
    public function setCountryCode($countryCode = null)
    {
        // validation for constraint: string
        if (!is_null($countryCode) && !is_string($countryCode)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($countryCode, true), gettype($countryCode)), __LINE__);
        }
        $this->countryCode = $countryCode;
        return $this;
    }
    /**
     * Get vatNumber value
     * @return string|null
     */
    public function getVatNumber()
    {
        return $this->vatNumber;
    }
    /**
     * Set vatNumber value
     * @param string $vatNumber
     * @return \EuVies\CheckVat
     */
    public function setVatNumber($vatNumber = null)
    {
        // validation for constraint: string
        if (!is_null($vatNumber) && !is_string($vatNumber)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($vatNumber, true), gettype($vatNumber)), __LINE__);
        }
        $this->vatNumber = $vatNumber;
        return $this;
    }
    /**
     * Method called when an object has been exported with var_export() functions
     * It allows to return an object instantiated with the values
     * @see AbstractStructBase::__set_state()
     * @uses AbstractStructBase::__set_state()
     * @param array $array the exported values
     * @return \EuVies\CheckVat
     */
    public static function __set_state(array $array)
    {
        return parent::__set_state($array);
    }
    /**
     * Method returning the class name
     * @return string __CLASS__
     */
    public function __toString()
    {
        return __CLASS__;
    }
}
