PHP Class eZ\Publish\Core\FieldType\Validator\StringLengthValidator

Inheritance: extends eZ\Publish\Core\FieldType\Validator
Datei anzeigen Open project: ezsystems/ezpublish-kernel Class Usage Examples

Protected Properties

Property Type Description
$constraints
$constraintsSchema

Public Methods

Method Description
validate ( Value $value ) : boolean Checks if the string $value is in desired range.
validateConstraints ( $constraints )

Protected Methods

Method Description
validateConstraintsOrder ( $constraints ) : boolean Check if max string length is greater or equal than min string length in case both are set. Returns also true in case one of them is not set.

Method Details

validate() public method

The range is determined by $maxStringLength and $minStringLength.
public validate ( Value $value ) : boolean
$value eZ\Publish\Core\FieldType\Value
return boolean

validateConstraints() public method

public validateConstraints ( $constraints )

validateConstraintsOrder() protected method

Check if max string length is greater or equal than min string length in case both are set. Returns also true in case one of them is not set.
protected validateConstraintsOrder ( $constraints ) : boolean
$constraints
return boolean

Property Details

$constraints protected_oe property

protected $constraints

$constraintsSchema protected_oe property

protected $constraintsSchema