SDK for PHP 3.x

TreeRule extends AbstractRule
in package

A rule within a rule set. All rules contain a conditions property, which can be empty, and documentation about the rule.

Table of Contents

Methods

__construct()  : mixed
evaluate()  : mixed
If a tree rule's conditions evaluate successfully, iterate over its subordinate rules and return a result if there is one. If any of the subsequent rules are trees, the function will recurse until it reaches an error or an endpoint rule
getConditions()  : array<string|int, mixed>
getDocumentation()  : mixed
getRules()  : array<string|int, mixed>

Methods

__construct()

public __construct(array<string|int, mixed> $definition) : mixed
Parameters
$definition : array<string|int, mixed>

evaluate()

If a tree rule's conditions evaluate successfully, iterate over its subordinate rules and return a result if there is one. If any of the subsequent rules are trees, the function will recurse until it reaches an error or an endpoint rule

public evaluate(array<string|int, mixed> $inputParameters, RulesetStandardLibrary $standardLibrary) : mixed
Parameters
$inputParameters : array<string|int, mixed>
$standardLibrary : RulesetStandardLibrary

getConditions()

public getConditions() : array<string|int, mixed>
Return values
array<string|int, mixed>

getDocumentation()

public getDocumentation() : mixed

getRules()

public getRules() : array<string|int, mixed>
Return values
array<string|int, mixed>
On this page