PHP Class ValidationLogicCriterion, silverstripe-zenvalidator

Inheritance: extends Object
Show file Open project: sheadawson/silverstripe-zenvalidator Class Usage Examples

Protected Properties

Property Type Description
$master string The name of the form field that is controlling the Validation
$operator string The comparison function to use, e.g. "EqualTo"
$set ValidationLogicCriteria The parent {@link ValidationLogicCriteria}
$value mixed The value to compare to

Public Methods

Method Description
__construct ( string $master, string $operator, string $value, ValidationLogicCriteria $set ) Constructor
getMaster ( ) : string Accessor for the master field
phpOperator ( )
toPHP ( ) : string Returns a string of php code to be evaluated

Method Details

__construct() public method

Constructor
public __construct ( string $master, string $operator, string $value, ValidationLogicCriteria $set )
$master string The name of the master field
$operator string The name of the comparison function
$value string The value to compare to
$set ValidationLogicCriteria The parent criteria set

getMaster() public method

Accessor for the master field
public getMaster ( ) : string
return string

phpOperator() public method

public phpOperator ( )

toPHP() public method

Returns a string of php code to be evaluated
public toPHP ( ) : string
return string

Property Details

$master protected property

The name of the form field that is controlling the Validation
protected string $master
return string

$operator protected property

The comparison function to use, e.g. "EqualTo"
protected string $operator
return string

$set protected property

The parent {@link ValidationLogicCriteria}
protected ValidationLogicCriteria $set
return ValidationLogicCriteria

$value protected property

The value to compare to
protected mixed $value
return mixed