<?php
use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for pinCredentials StructType
 * Meta informations extracted from the WSDL
 * - documentation: Not Applicable for add. These groups get automatically added once an user is added. | Not Applicable for add. These groups get automatically added once an user is added.
 * @subpackage Structs
 */
class PinCredentials extends AbstractStructBase
{
    /**
     * The pinCredPolicyName
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * - nillable: false
     * @var XFkType
     */
    public $pinCredPolicyName;
    /**
     * The pinCredUserCantChange
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * - nillable: false
     * - pattern: (t)|(f)|(true)|(false)|(0)|(1)
     * @var string
     */
    public $pinCredUserCantChange;
    /**
     * The pinCredUserMustChange
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * - nillable: false
     * - pattern: (t)|(f)|(true)|(false)|(0)|(1)
     * @var string
     */
    public $pinCredUserMustChange;
    /**
     * The pinCredDoesNotExpire
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * - nillable: false
     * - pattern: (t)|(f)|(true)|(false)|(0)|(1)
     * @var string
     */
    public $pinCredDoesNotExpire;
    /**
     * The pinCredTimeChanged
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * - nillable: false
     * - pattern: (t)|(f)|(true)|(false)|(0)|(1)
     * @var string
     */
    public $pinCredTimeChanged;
    /**
     * The pinCredTimeAdminLockout
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $pinCredTimeAdminLockout;
    /**
     * The pinCredLockedByAdministrator
     * Meta informations extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * - pattern: (t)|(f)|(true)|(false)|(0)|(1)
     * @var string
     */
    public $pinCredLockedByAdministrator;
    /**
     * Constructor method for pinCredentials
     * @uses PinCredentials::setPinCredPolicyName()
     * @uses PinCredentials::setPinCredUserCantChange()
     * @uses PinCredentials::setPinCredUserMustChange()
     * @uses PinCredentials::setPinCredDoesNotExpire()
     * @uses PinCredentials::setPinCredTimeChanged()
     * @uses PinCredentials::setPinCredTimeAdminLockout()
     * @uses PinCredentials::setPinCredLockedByAdministrator()
     * @param XFkType $pinCredPolicyName
     * @param string $pinCredUserCantChange
     * @param string $pinCredUserMustChange
     * @param string $pinCredDoesNotExpire
     * @param string $pinCredTimeChanged
     * @param string $pinCredTimeAdminLockout
     * @param string $pinCredLockedByAdministrator
     */
    public function __construct(XFkType $pinCredPolicyName = null, $pinCredUserCantChange = null, $pinCredUserMustChange = null, $pinCredDoesNotExpire = null, $pinCredTimeChanged = null, $pinCredTimeAdminLockout = null, $pinCredLockedByAdministrator = null)
    {
        $this
            ->setPinCredPolicyName($pinCredPolicyName)
            ->setPinCredUserCantChange($pinCredUserCantChange)
            ->setPinCredUserMustChange($pinCredUserMustChange)
            ->setPinCredDoesNotExpire($pinCredDoesNotExpire)
            ->setPinCredTimeChanged($pinCredTimeChanged)
            ->setPinCredTimeAdminLockout($pinCredTimeAdminLockout)
            ->setPinCredLockedByAdministrator($pinCredLockedByAdministrator);
    }
    /**
     * Get pinCredPolicyName value
     * @return XFkType|null
     */
    public function getPinCredPolicyName()
    {
        return $this->pinCredPolicyName;
    }
    /**
     * Set pinCredPolicyName value
     * @param XFkType $pinCredPolicyName
     * @return PinCredentials
     */
    public function setPinCredPolicyName(XFkType $pinCredPolicyName = null)
    {
        $this->pinCredPolicyName = $pinCredPolicyName;
        return $this;
    }
    /**
     * Get pinCredUserCantChange value
     * @return string|null
     */
    public function getPinCredUserCantChange()
    {
        return $this->pinCredUserCantChange;
    }
    /**
     * Set pinCredUserCantChange value
     * @param string $pinCredUserCantChange
     * @return PinCredentials
     */
    public function setPinCredUserCantChange($pinCredUserCantChange = null)
    {
        // validation for constraint: pattern
        if (is_scalar($pinCredUserCantChange) && !preg_match('/(t)|(f)|(true)|(false)|(0)|(1)/', $pinCredUserCantChange)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a scalar value that matches "(t)|(f)|(true)|(false)|(0)|(1)", "%s" given', var_export($pinCredUserCantChange, true)), __LINE__);
        }
        // validation for constraint: string
        if (!is_null($pinCredUserCantChange) && !is_string($pinCredUserCantChange)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($pinCredUserCantChange)), __LINE__);
        }
        $this->pinCredUserCantChange = $pinCredUserCantChange;
        return $this;
    }
    /**
     * Get pinCredUserMustChange value
     * @return string|null
     */
    public function getPinCredUserMustChange()
    {
        return $this->pinCredUserMustChange;
    }
    /**
     * Set pinCredUserMustChange value
     * @param string $pinCredUserMustChange
     * @return PinCredentials
     */
    public function setPinCredUserMustChange($pinCredUserMustChange = null)
    {
        // validation for constraint: pattern
        if (is_scalar($pinCredUserMustChange) && !preg_match('/(t)|(f)|(true)|(false)|(0)|(1)/', $pinCredUserMustChange)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a scalar value that matches "(t)|(f)|(true)|(false)|(0)|(1)", "%s" given', var_export($pinCredUserMustChange, true)), __LINE__);
        }
        // validation for constraint: string
        if (!is_null($pinCredUserMustChange) && !is_string($pinCredUserMustChange)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($pinCredUserMustChange)), __LINE__);
        }
        $this->pinCredUserMustChange = $pinCredUserMustChange;
        return $this;
    }
    /**
     * Get pinCredDoesNotExpire value
     * @return string|null
     */
    public function getPinCredDoesNotExpire()
    {
        return $this->pinCredDoesNotExpire;
    }
    /**
     * Set pinCredDoesNotExpire value
     * @param string $pinCredDoesNotExpire
     * @return PinCredentials
     */
    public function setPinCredDoesNotExpire($pinCredDoesNotExpire = null)
    {
        // validation for constraint: pattern
        if (is_scalar($pinCredDoesNotExpire) && !preg_match('/(t)|(f)|(true)|(false)|(0)|(1)/', $pinCredDoesNotExpire)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a scalar value that matches "(t)|(f)|(true)|(false)|(0)|(1)", "%s" given', var_export($pinCredDoesNotExpire, true)), __LINE__);
        }
        // validation for constraint: string
        if (!is_null($pinCredDoesNotExpire) && !is_string($pinCredDoesNotExpire)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($pinCredDoesNotExpire)), __LINE__);
        }
        $this->pinCredDoesNotExpire = $pinCredDoesNotExpire;
        return $this;
    }
    /**
     * Get pinCredTimeChanged value
     * @return string|null
     */
    public function getPinCredTimeChanged()
    {
        return $this->pinCredTimeChanged;
    }
    /**
     * Set pinCredTimeChanged value
     * @param string $pinCredTimeChanged
     * @return PinCredentials
     */
    public function setPinCredTimeChanged($pinCredTimeChanged = null)
    {
        // validation for constraint: pattern
        if (is_scalar($pinCredTimeChanged) && !preg_match('/(t)|(f)|(true)|(false)|(0)|(1)/', $pinCredTimeChanged)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a scalar value that matches "(t)|(f)|(true)|(false)|(0)|(1)", "%s" given', var_export($pinCredTimeChanged, true)), __LINE__);
        }
        // validation for constraint: string
        if (!is_null($pinCredTimeChanged) && !is_string($pinCredTimeChanged)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($pinCredTimeChanged)), __LINE__);
        }
        $this->pinCredTimeChanged = $pinCredTimeChanged;
        return $this;
    }
    /**
     * Get pinCredTimeAdminLockout value
     * @return string|null
     */
    public function getPinCredTimeAdminLockout()
    {
        return $this->pinCredTimeAdminLockout;
    }
    /**
     * Set pinCredTimeAdminLockout value
     * @param string $pinCredTimeAdminLockout
     * @return PinCredentials
     */
    public function setPinCredTimeAdminLockout($pinCredTimeAdminLockout = null)
    {
        // validation for constraint: string
        if (!is_null($pinCredTimeAdminLockout) && !is_string($pinCredTimeAdminLockout)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($pinCredTimeAdminLockout)), __LINE__);
        }
        $this->pinCredTimeAdminLockout = $pinCredTimeAdminLockout;
        return $this;
    }
    /**
     * Get pinCredLockedByAdministrator value
     * @return string|null
     */
    public function getPinCredLockedByAdministrator()
    {
        return $this->pinCredLockedByAdministrator;
    }
    /**
     * Set pinCredLockedByAdministrator value
     * @param string $pinCredLockedByAdministrator
     * @return PinCredentials
     */
    public function setPinCredLockedByAdministrator($pinCredLockedByAdministrator = null)
    {
        // validation for constraint: pattern
        if (is_scalar($pinCredLockedByAdministrator) && !preg_match('/(t)|(f)|(true)|(false)|(0)|(1)/', $pinCredLockedByAdministrator)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a scalar value that matches "(t)|(f)|(true)|(false)|(0)|(1)", "%s" given', var_export($pinCredLockedByAdministrator, true)), __LINE__);
        }
        // validation for constraint: string
        if (!is_null($pinCredLockedByAdministrator) && !is_string($pinCredLockedByAdministrator)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($pinCredLockedByAdministrator)), __LINE__);
        }
        $this->pinCredLockedByAdministrator = $pinCredLockedByAdministrator;
        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 PinCredentials
     */
    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__;
    }
}
