Typo3QuerySettings

class \TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings

Implements
QuerySettingsInterface

Query settings, reflects the settings unique to TYPO3 CMS.

Table of Contents

Interfaces

QuerySettingsInterface
A query settings interface. This interface is NOT part of the TYPO3.Flow API.

Properties

$configurationManager  : ConfigurationManagerInterface
$context  : Context
$enableFieldsToBeIgnored  : array
An array of column names in the enable columns array (array keys in $GLOBALS['TCA'][$table]['ctrl']['enablecolumns']), to be ignored while building the query statement
$ignoreEnableFields  : bool
A flag indicating whether all or some enable fields should be ignored. If TRUE, all enable fields are ignored.
$includeDeleted  : bool
Flag whether deleted records should be included in the result set.
$languageOverlayMode  : bool
Representing sys_language_overlay only valid for current context
$languageUid  : int
Representing sys_language_uid only valid for current context
$respectStoragePage  : bool
Flag if the storage page should be respected for the query.
$respectSysLanguage  : bool
Flag if the sys_language_uid should be respected (default is TRUE).
$storagePageIds  : array
the pid(s) of the storage page(s) that should be respected for the query.

Methods

__construct()  : mixed
getEnableFieldsToBeIgnored()  : array
An array of column names in the enable columns array (array keys in $GLOBALS['TCA'][$table]['ctrl']['enablecolumns']), to be ignored while building the query statement.
getIgnoreEnableFields()  : bool
The returned value indicates whether all or some enable fields should be ignored.
getIncludeDeleted()  : bool
Returns if the query should return objects that are deleted.
getLanguageMode()  : string
Language Mode is NOT used anymore, so just avoid using it. Will be deprecated in the future.
getLanguageOverlayMode()  : mixed
getLanguageUid()  : int
getRespectStoragePage()  : bool
Returns the state, if the storage page should be respected for the query.
getRespectSysLanguage()  : bool
Returns the state, if record language should be checked when querying
getStoragePageIds()  : array
Returns the pid(s) of the storage page(s) that should be respected for the query.
setEnableFieldsToBeIgnored()  : QuerySettingsInterface
An array of column names in the enable columns array (array keys in $GLOBALS['TCA'][$table]['ctrl']['enablecolumns']), to be ignored while building the query statement. Adding a column name here effectively switches off filtering by this column. This setting is only taken into account if $this->ignoreEnableFields = TRUE.
setIgnoreEnableFields()  : QuerySettingsInterface
Sets a flag indicating whether all or some enable fields should be ignored. If TRUE, all enable fields are ignored.
setIncludeDeleted()  : QuerySettingsInterface
Sets the flag if the query should return objects that are deleted.
setLanguageMode()  : QuerySettingsInterface
Language Mode is NOT used anymore, so just avoid using it. Will be deprecated in the future.
setLanguageOverlayMode()  : QuerySettingsInterface
setLanguageUid()  : QuerySettingsInterface
setRespectStoragePage()  : QuerySettingsInterface
Sets the flag if the storage page should be respected for the query.
setRespectSysLanguage()  : QuerySettingsInterface
Sets the flag if record language should be respected when querying.
setStoragePageIds()  : QuerySettingsInterface
Sets the pid(s) of the storage page(s) that should be respected for the query.

Properties

$enableFieldsToBeIgnored

An array of column names in the enable columns array (array keys in $GLOBALS['TCA'][$table]['ctrl']['enablecolumns']), to be ignored while building the query statement

protected array $enableFieldsToBeIgnored = []

$ignoreEnableFields

A flag indicating whether all or some enable fields should be ignored. If TRUE, all enable fields are ignored.

protected bool $ignoreEnableFields = false

If--in addition to this--enableFieldsToBeIgnored is set, only fields specified there are ignored. If FALSE, all enable fields are taken into account, regardless of the enableFieldsToBeIgnored setting.

$includeDeleted

Flag whether deleted records should be included in the result set.

protected bool $includeDeleted = false

$languageOverlayMode

Representing sys_language_overlay only valid for current context

protected bool $languageOverlayMode = true

$languageUid

Representing sys_language_uid only valid for current context

protected int $languageUid = 0

$respectStoragePage

Flag if the storage page should be respected for the query.

protected bool $respectStoragePage = true

$respectSysLanguage

Flag if the sys_language_uid should be respected (default is TRUE).

protected bool $respectSysLanguage = true

$storagePageIds

the pid(s) of the storage page(s) that should be respected for the query.

protected array $storagePageIds = []

Methods

getEnableFieldsToBeIgnored()

An array of column names in the enable columns array (array keys in $GLOBALS['TCA'][$table]['ctrl']['enablecolumns']), to be ignored while building the query statement.

public getEnableFieldsToBeIgnored() : array

Tags

see
getIgnoreEnableFields()

Return values

array

getIgnoreEnableFields()

The returned value indicates whether all or some enable fields should be ignored.

public getIgnoreEnableFields() : bool

If TRUE, all enable fields are ignored. If--in addition to this--enableFieldsToBeIgnored is set, only fields specified there are ignored. If FALSE, all enable fields are taken into account, regardless of the enableFieldsToBeIgnored setting.

Tags

see
getEnableFieldsToBeIgnored()

Return values

bool

getIncludeDeleted()

Returns if the query should return objects that are deleted.

public getIncludeDeleted() : bool

Return values

bool

getLanguageMode()

Language Mode is NOT used anymore, so just avoid using it. Will be deprecated in the future.

public getLanguageMode() : string

Deprecated

since TYPO3 11.0, will be removed in version 12.0

Return values

string —

NULL, "content_fallback", "strict" or "ignore"

getLanguageOverlayMode()

public getLanguageOverlayMode() : mixed

Return values

mixed —

TRUE, FALSE or "hideNonTranslated"

getLanguageUid()

public getLanguageUid() : int

Return values

int

getRespectStoragePage()

Returns the state, if the storage page should be respected for the query.

public getRespectStoragePage() : bool

Return values

bool —

TRUE, if the storage page should be respected; otherwise FALSE.

getRespectSysLanguage()

Returns the state, if record language should be checked when querying

public getRespectSysLanguage() : bool

Return values

bool —

TRUE if TYPO3 language settings are to be applied

getStoragePageIds()

Returns the pid(s) of the storage page(s) that should be respected for the query.

public getStoragePageIds() : array

Return values

array —

list of integers that each represent a storage page id

setEnableFieldsToBeIgnored()

An array of column names in the enable columns array (array keys in $GLOBALS['TCA'][$table]['ctrl']['enablecolumns']), to be ignored while building the query statement. Adding a column name here effectively switches off filtering by this column. This setting is only taken into account if $this->ignoreEnableFields = TRUE.

public setEnableFieldsToBeIgnored(array $enableFieldsToBeIgnored) : QuerySettingsInterface

Parameters

$enableFieldsToBeIgnored : array

Tags

see
setIgnoreEnableFields()

Return values

QuerySettingsInterface

setIgnoreEnableFields()

Sets a flag indicating whether all or some enable fields should be ignored. If TRUE, all enable fields are ignored.

public setIgnoreEnableFields(bool $ignoreEnableFields) : QuerySettingsInterface

If--in addition to this--enableFieldsToBeIgnored is set, only fields specified there are ignored. If FALSE, all enable fields are taken into account, regardless of the enableFieldsToBeIgnored setting.

Parameters

$ignoreEnableFields : bool

Tags

see
setEnableFieldsToBeIgnored()

Return values

QuerySettingsInterface

setLanguageMode()

Language Mode is NOT used anymore, so just avoid using it. Will be deprecated in the future.

public setLanguageMode([string $languageMode = '' ]) : QuerySettingsInterface

Deprecated

since TYPO3 11.0, will be removed in version 12.0

Parameters

$languageMode : string = ''

Return values

QuerySettingsInterface —

instance of $this to allow method chaining

setLanguageOverlayMode()

public setLanguageOverlayMode([mixed $languageOverlayMode = false ]) : QuerySettingsInterface

Parameters

$languageOverlayMode : mixed = false

TRUE, FALSE or "hideNonTranslated"

Return values

QuerySettingsInterface —

instance of $this to allow method chaining

setRespectStoragePage()

Sets the flag if the storage page should be respected for the query.

public setRespectStoragePage(bool $respectStoragePage) : QuerySettingsInterface

Parameters

$respectStoragePage : bool

If TRUE the storage page ID will be determined and the statement will be extended accordingly.

Return values

QuerySettingsInterface

setRespectSysLanguage()

Sets the flag if record language should be respected when querying.

public setRespectSysLanguage(bool $respectSysLanguage) : QuerySettingsInterface

Parameters

$respectSysLanguage : bool

TRUE if TYPO3 language settings are to be applied

Return values

QuerySettingsInterface

setStoragePageIds()

Sets the pid(s) of the storage page(s) that should be respected for the query.

public setStoragePageIds(array $storagePageIds) : QuerySettingsInterface

Parameters

$storagePageIds : array

If given the storage page IDs will be determined and the statement will be extended accordingly.

Return values

QuerySettingsInterface
On this page