TYPO3CMS  8
 All Classes Namespaces Files Functions Variables Pages
BackendWorkspaceRestriction Class Reference
Inheritance diagram for BackendWorkspaceRestriction:
QueryRestrictionInterface

Public Member Functions

 __construct (int $workspaceId=null, $includeRowsForWorkspaceOverlay=true)
 
 buildExpression (array $queriedTables, ExpressionBuilder $expressionBuilder)
 

Protected Attributes

 $workspaceId
 
 $includeRowsForWorkspaceOverlay
 

Detailed Description

Restriction to make queries in TYPO3 backend context versioning/ workspace aware

Definition at line 25 of file BackendWorkspaceRestriction.php.

Constructor & Destructor Documentation

__construct ( int  $workspaceId = null,
  $includeRowsForWorkspaceOverlay = true 
)
Parameters
int$workspaceId
bool$includeRowsForWorkspaceOverlay

Definition at line 41 of file BackendWorkspaceRestriction.php.

References $GLOBALS, BackendWorkspaceRestriction\$includeRowsForWorkspaceOverlay, and BackendWorkspaceRestriction\$workspaceId.

Member Function Documentation

buildExpression ( array  $queriedTables,
ExpressionBuilder  $expressionBuilder 
)

Main method to build expressions for given tables

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

Implements QueryRestrictionInterface.

Definition at line 54 of file BackendWorkspaceRestriction.php.

References $GLOBALS, VersionState\DEFAULT_STATE, ExpressionBuilder\eq(), ExpressionBuilder\lte(), and ExpressionBuilder\orX().

Member Data Documentation

$includeRowsForWorkspaceOverlay
protected
$workspaceId
protected