FolderRestriction extends AbstractRestrictionContainer

Limits result to storage given by the folder and also restricts result to the given folder, respecting whether the storage has hierarchical identifiers or not.

Table of Contents

Properties

$enforcedRestrictions  : array<string|int, QueryRestrictionInterface>
$restrictions  : array<string|int, QueryRestrictionInterface>

Methods

__construct()  : mixed
add()  : QueryRestrictionContainerInterface
Add a new restriction instance to this collection
buildExpression()  : CompositeExpression
Main method to build expressions for given tables.
removeAll()  : QueryRestrictionContainerInterface
Removes all restrictions stored within this container
removeByType()  : QueryRestrictionContainerInterface
Remove restriction of a given type
createRestriction()  : QueryRestrictionInterface
Factory method for restrictions.

Properties

Methods

__construct()

public __construct(Folder $folder, bool $recursive) : mixed
Parameters
$folder : Folder
$recursive : bool

buildExpression()

Main method to build expressions for given tables.

public buildExpression(array<string|int, mixed> $queriedTables, ExpressionBuilder $expressionBuilder) : CompositeExpression

Iterating over all registered expressions and combine them with AND

Parameters
$queriedTables : array<string|int, mixed>

Array of tables, where array key is table alias and value is a table name

$expressionBuilder : ExpressionBuilder

Expression builder instance to add restrictions with

Return values
CompositeExpression

The result of query builder expression(s)


        
On this page

Search results