ManaPHP\Security\CsrfToken::__construct PHP Метод

__construct() публичный Метод

CsrfToken constructor.
public __construct ( integer | string | array $options = [] )
$options integer | string | array
    public function __construct($options = [])
    {
        if (is_int($options) || is_string($options)) {
            $_options = ['length' => $options];
        } elseif (is_object($options)) {
            $_options = (array) $options;
        } elseif (is_array($options)) {
            $_options = (array) $options;
        }
        if (isset($_options['length'])) {
            $this->_length = $_options['length'];
        }
        if (isset($_options['useCookie'])) {
            $this->_useCookie = $_options['useCookie'];
        }
        if (isset($_options['name'])) {
            $this->_name = $_options['name'];
        }
    }