Fuel\Validation\Rule\Enum::validate PHP Метод

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

Performs validation on the given value
С версии: 2.0
public validate ( mixed $value, string $field = null, array $allFields = null ) : boolean
$value mixed Value to validate
$field string Unused by this rule
$allFields array Unused by this rule
Результат boolean
    public function validate($value, $field = null, $allFields = null)
    {
        $values = $this->getParameter();
        return in_array($value, $values, $this->strict);
    }