AnewtValidatorLength class

Validator to check the length of a string.

Class Overview

Validator to check the length of a string.

Public Methods

__construct($min=null, $max=null)

Create a new AnewtValidatorLength instance.

Parameters

$min

Minimum allowable value. Provide null for no limit.

$max

Maximum allowable value. Provide null for no limit.

is_valid($value)

Checks for validity.

The return value should be true for valid values, and false otherwise.

Parameters

$value

The value to check for validity.

Return value

True if the value is valid, false otherwise.

Private Attributes

$_min [private]

Minimal value.

$_max [private]

Maximal value.

Inheritance

Base Classes

Inherited members