‪TYPO3CMS  ‪main
TYPO3\CMS\Core\Database\Query\Restriction\PageIdListRestriction Class Reference
Inheritance diagram for TYPO3\CMS\Core\Database\Query\Restriction\PageIdListRestriction:
TYPO3\CMS\Core\Database\Query\Restriction\QueryRestrictionInterface

Public Member Functions

 __construct (private readonly array $tableNames, private readonly array $pageIds)
 
CompositeExpression buildExpression (array $queriedTables, ExpressionBuilder $expressionBuilder)
 

Detailed Description

Restriction to filter records that only reside on a specific list of page IDs

Definition at line 26 of file PageIdListRestriction.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Core\Database\Query\Restriction\PageIdListRestriction::__construct ( private readonly array  $tableNames,
private readonly array  $pageIds 
)

Definition at line 28 of file PageIdListRestriction.php.

Member Function Documentation

◆ buildExpression()

CompositeExpression TYPO3\CMS\Core\Database\Query\Restriction\PageIdListRestriction::buildExpression ( array  $queriedTables,
ExpressionBuilder  $expressionBuilder 
)

Main method to build expressions for given tables

Parameters
array$queriedTables‪Array of tables, where array key is table alias and value is a table name
ExpressionBuilder$expressionBuilderExpression builder instance to add restrictions with
Returns
‪CompositeExpression The result of query builder expression(s)

Implements TYPO3\CMS\Core\Database\Query\Restriction\QueryRestrictionInterface.

Definition at line 40 of file PageIdListRestriction.php.

References TYPO3\CMS\Core\Database\Query\Expression\ExpressionBuilder\and(), and TYPO3\CMS\Core\Database\Query\Expression\ExpressionBuilder\in().