<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for ContactCategory StructType
 * Meta information extracted from the WSDL
 * - type: listAcct:ContactCategory
 * @subpackage Structs
 */
class ContactCategory extends Record
{
    /**
     * The name
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * @var string
     */
    public $name;
    /**
     * The private
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * @var bool
     */
    public $private;
    /**
     * The sync
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * @var bool
     */
    public $sync;
    /**
     * The isInactive
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * @var bool
     */
    public $isInactive;
    /**
     * The internalId
     * @var string
     */
    public $internalId;
    /**
     * The externalId
     * @var string
     */
    public $externalId;
    /**
     * Constructor method for ContactCategory
     * @uses ContactCategory::setName()
     * @uses ContactCategory::setPrivate()
     * @uses ContactCategory::setSync()
     * @uses ContactCategory::setIsInactive()
     * @uses ContactCategory::setInternalId()
     * @uses ContactCategory::setExternalId()
     * @param string $name
     * @param bool $private
     * @param bool $sync
     * @param bool $isInactive
     * @param string $internalId
     * @param string $externalId
     */
    public function __construct($name = null, $private = null, $sync = null, $isInactive = null, $internalId = null, $externalId = null)
    {
        $this
            ->setName($name)
            ->setPrivate($private)
            ->setSync($sync)
            ->setIsInactive($isInactive)
            ->setInternalId($internalId)
            ->setExternalId($externalId);
    }
    /**
     * Get name value
     * @return string|null
     */
    public function getName()
    {
        return $this->name;
    }
    /**
     * Set name value
     * @param string $name
     * @return \StructType\ContactCategory
     */
    public function setName($name = null)
    {
        // validation for constraint: string
        if (!is_null($name) && !is_string($name)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($name, true), gettype($name)), __LINE__);
        }
        $this->name = $name;
        return $this;
    }
    /**
     * Get private value
     * @return bool|null
     */
    public function getPrivate()
    {
        return $this->private;
    }
    /**
     * Set private value
     * @param bool $private
     * @return \StructType\ContactCategory
     */
    public function setPrivate($private = null)
    {
        // validation for constraint: boolean
        if (!is_null($private) && !is_bool($private)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a bool, %s given', var_export($private, true), gettype($private)), __LINE__);
        }
        $this->private = $private;
        return $this;
    }
    /**
     * Get sync value
     * @return bool|null
     */
    public function getSync()
    {
        return $this->sync;
    }
    /**
     * Set sync value
     * @param bool $sync
     * @return \StructType\ContactCategory
     */
    public function setSync($sync = null)
    {
        // validation for constraint: boolean
        if (!is_null($sync) && !is_bool($sync)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a bool, %s given', var_export($sync, true), gettype($sync)), __LINE__);
        }
        $this->sync = $sync;
        return $this;
    }
    /**
     * Get isInactive value
     * @return bool|null
     */
    public function getIsInactive()
    {
        return $this->isInactive;
    }
    /**
     * Set isInactive value
     * @param bool $isInactive
     * @return \StructType\ContactCategory
     */
    public function setIsInactive($isInactive = null)
    {
        // validation for constraint: boolean
        if (!is_null($isInactive) && !is_bool($isInactive)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a bool, %s given', var_export($isInactive, true), gettype($isInactive)), __LINE__);
        }
        $this->isInactive = $isInactive;
        return $this;
    }
    /**
     * Get internalId value
     * @return string|null
     */
    public function getInternalId()
    {
        return $this->internalId;
    }
    /**
     * Set internalId value
     * @param string $internalId
     * @return \StructType\ContactCategory
     */
    public function setInternalId($internalId = null)
    {
        // validation for constraint: string
        if (!is_null($internalId) && !is_string($internalId)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($internalId, true), gettype($internalId)), __LINE__);
        }
        $this->internalId = $internalId;
        return $this;
    }
    /**
     * Get externalId value
     * @return string|null
     */
    public function getExternalId()
    {
        return $this->externalId;
    }
    /**
     * Set externalId value
     * @param string $externalId
     * @return \StructType\ContactCategory
     */
    public function setExternalId($externalId = null)
    {
        // validation for constraint: string
        if (!is_null($externalId) && !is_string($externalId)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($externalId, true), gettype($externalId)), __LINE__);
        }
        $this->externalId = $externalId;
        return $this;
    }
}
