Property | Type | Description | |
---|---|---|---|
$filterOrder | array | This is important as changing the order can affect the results of certain filters, such as limit and offset. It also allows increased performance by allowing filters with high filtering potential to be run earlier. |
Method | Description | |
---|---|---|
__construct ( array | null $attributes = null ) | Initialises the criteria model, forcing the element type to be a Neo block. | |
copy ( ) : |
Returns a clone of the criteria model. | |
count ( ) : integer | Returns the total number of elements matched by this criteria. | |
setAllElements ( array $elements ) | Sets all the elements (blocks) to be filtered against in Live Preview mode. | |
setAttribute ( string $name, mixed $value ) : boolean | Sets a filter value for the criteria model, then reruns Live Preview filtering. |
Method | Description | |
---|---|---|
__ancestorDist ( array $elements, integer $value ) : array | ||
__ancestorOf ( array $elements, |
||
__collapsed ( array $elements, |
||
__descendantDist ( array $elements, integer $value ) : array | ||
__descendantOf ( array $elements, |
||
__fieldId ( array $elements, integer $value ) : array | ||
__id ( array $elements, integer $value ) : array | ||
__level ( array $elements, integer $value ) : array | ||
__limit ( array $elements, integer $value ) : array | ||
__nextSiblingOf ( array $elements, int\Neo_BlockModel $value ) : array | ||
__offset ( array $elements, integer $value ) : array | ||
__positionedAfter ( array $elements, int\Neo_BlockModel $value ) : array | ||
__positionedBefore ( array $elements, int\Neo_BlockModel $value ) : array | ||
__prevSiblingOf ( array $elements, int\Neo_BlockModel $value ) : array | ||
__relatedTo ( array $elements, $value ) : array | ||
__search ( array $elements, $value ) : array | ||
__siblingOf ( array $elements, int\Neo_BlockModel $value ) : array | ||
__status ( array $elements, |
||
__type ( array $elements, string $value ) : array | ||
__typeId ( array $elements, integer $value ) : array | ||
getState ( ) : array | Returns all saved, private settings for the criteria model, to be used when copying. | |
setState ( array\Neo_CriteriaModel $state ) | Sets all saved, private settings to the criteria model, to be used when copying. |
Method | Description | |
---|---|---|
_compareInt ( integer $value, string\int $comparison ) : boolean | Compares an integer against a criteria model integer comparison string, or integer. | |
_getBlock ( int\Neo_BlockModel $block ) : bool\Neo_BlockModel | Returns a block model given an ID, or an actual block model. | |
_indexOfBlock ( array $elements, |
Finds the position of a block inside a list of blocks. | |
_indexOfRootBlock ( array $elements, |
Finds the position of the block who is it's furthest ancestor to the passed block. | |
_runCriteria ( ) | Runs Live Preview filtering and saves it's output to the criteria model. |
protected __ancestorOf ( array $elements, |
||
$elements | array | |
$value | ||
return | array |
protected __collapsed ( array $elements, |
||
$elements | array | |
$value | ||
return | array |
public __construct ( array | null $attributes = null ) | ||
$attributes | array | null |
protected __descendantOf ( array $elements, |
||
$elements | array | |
$value | ||
return | array |
protected __nextSiblingOf ( array $elements, int\Neo_BlockModel $value ) : array | ||
$elements | array | |
$value | int\Neo_BlockModel | |
return | array |
protected __positionedAfter ( array $elements, int\Neo_BlockModel $value ) : array | ||
$elements | array | |
$value | int\Neo_BlockModel | |
return | array |
protected __positionedBefore ( array $elements, int\Neo_BlockModel $value ) : array | ||
$elements | array | |
$value | int\Neo_BlockModel | |
return | array |
protected __prevSiblingOf ( array $elements, int\Neo_BlockModel $value ) : array | ||
$elements | array | |
$value | int\Neo_BlockModel | |
return | array |
protected __siblingOf ( array $elements, int\Neo_BlockModel $value ) : array | ||
$elements | array | |
$value | int\Neo_BlockModel | |
return | array |
public copy ( ) : |
||
return |
public setAllElements ( array $elements ) | ||
$elements | array |
protected setState ( array\Neo_CriteriaModel $state ) | ||
$state | array\Neo_CriteriaModel |
protected array $filterOrder | ||
return | array |