public function __construct(array $options = [])
{
parent::__construct($options);
$options = $this->getOptions();
if (!isset($options['length'])) {
throw new \Gajus\Vlad\Exception\InvalidArgumentException('"length" option is required.');
}
if (!ctype_digit((string) $options['length'])) {
throw new \Gajus\Vlad\Exception\InvalidArgumentException('"length" option must be a whole number.');
}
}