TYPO3 CMS  TYPO3_6-2
TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings Class Reference
Inheritance diagram for TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings:
TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface Tx_Extbase_Persistence_Typo3QuerySettings

Public Member Functions

 setRespectStoragePage ($respectStoragePage)
 
 getRespectStoragePage ()
 
 setStoragePageIds (array $storagePageIds)
 
 getStoragePageIds ()
 
 setRespectSysLanguage ($respectSysLanguage)
 
 getRespectSysLanguage ()
 
 setLanguageOverlayMode ($languageOverlayMode=FALSE)
 
 getLanguageOverlayMode ()
 
 setLanguageMode ($languageMode='')
 
 getLanguageMode ()
 
 setLanguageUid ($languageUid)
 
 getLanguageUid ()
 
 setSysLanguageUid ($sysLanguageUid)
 
 getSysLanguageUid ()
 
 setIgnoreEnableFields ($ignoreEnableFields)
 
 getIgnoreEnableFields ()
 
 setEnableFieldsToBeIgnored ($enableFieldsToBeIgnored)
 
 getEnableFieldsToBeIgnored ()
 
 setIncludeDeleted ($includeDeleted)
 
 getIncludeDeleted ()
 
 setReturnRawQueryResult ($returnRawQueryResult)
 
 getReturnRawQueryResult ()
 
 usePreparedStatement ($usePreparedStatement)
 
 getUsePreparedStatement ()
 
 useQueryCache ($useQueryCache)
 
 getUseQueryCache ()
 

Protected Attributes

 $respectStoragePage = TRUE
 
 $storagePageIds = array()
 
 $ignoreEnableFields = FALSE
 
 $enableFieldsToBeIgnored = array()
 
 $includeDeleted = FALSE
 
 $respectSysLanguage = TRUE
 
 $languageOverlayMode = TRUE
 
 $languageMode = NULL
 
 $languageUid = 0
 
 $returnRawQueryResult = FALSE
 
 $usePreparedStatement = FALSE
 
 $useQueryCache = TRUE
 

Detailed Description

Query settings. This class is NOT part of the FLOW3 API. It reflects the settings unique to TYPO3 CMS.

Definition at line 24 of file Typo3QuerySettings.php.

Member Function Documentation

◆ getEnableFieldsToBeIgnored()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::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.

Returns
array
See also
getIgnoreEnableFields()

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 326 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$enableFieldsToBeIgnored.

◆ getIgnoreEnableFields()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getIgnoreEnableFields ( )

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

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.

Returns
bool
See also
getEnableFieldsToBeIgnored()

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 300 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$ignoreEnableFields.

◆ getIncludeDeleted()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getIncludeDeleted ( )

Returns if the query should return objects that are deleted.

Returns
bool

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 347 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$includeDeleted.

◆ getLanguageMode()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getLanguageMode ( )
Returns
string NULL, "content_fallback", "strict" or "ignore"

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 232 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$languageMode.

◆ getLanguageOverlayMode()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getLanguageOverlayMode ( )

◆ getLanguageUid()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getLanguageUid ( )

◆ getRespectStoragePage()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getRespectStoragePage ( )

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

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

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 160 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$respectStoragePage.

◆ getRespectSysLanguage()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getRespectSysLanguage ( )
Returns
bool TRUE if TYPO3 language settings are to be applied

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 198 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$respectSysLanguage.

◆ getReturnRawQueryResult()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getReturnRawQueryResult ( )

Returns the state, if the QueryResult should be returned unmapped.

Returns
bool TRUE, if the QueryResult should be returned unmapped; otherwise FALSE.
Deprecated:
since Extbase 6.2, will be removed two versions later. Please use argument in query->execute() instead.

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 370 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$returnRawQueryResult.

◆ getStoragePageIds()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getStoragePageIds ( )

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

Returns
array list of integers that each represent a storage page id

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 181 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$storagePageIds.

◆ getSysLanguageUid()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getSysLanguageUid ( )

Returns the language uid for the language overlay

Returns
int language uid for the language overlay
Deprecated:
since Extbase 6.2, will be removed two versions later. Use getLanguageUid() instead.

Definition at line 271 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\getLanguageUid(), and TYPO3\CMS\Core\Utility\GeneralUtility\logDeprecatedFunction().

◆ getUsePreparedStatement()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getUsePreparedStatement ( )

◆ getUseQueryCache()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::getUseQueryCache ( )

◆ setEnableFieldsToBeIgnored()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setEnableFieldsToBeIgnored (   $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. Adding a column name here effectively switches off filtering by this column. This setting is only taken into account if $this->ignoreEnableFields = TRUE.

Parameters
array$enableFieldsToBeIgnored
Returns
QuerySettingsInterface
See also
setIgnoreEnableFields()

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 314 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$enableFieldsToBeIgnored.

◆ setIgnoreEnableFields()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setIgnoreEnableFields (   $ignoreEnableFields)

Sets a flag indicating whether all or some enable fields should be ignored. 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.

Parameters
bool$ignoreEnableFields
Returns
QuerySettingsInterface
See also
setEnableFieldsToBeIgnored()

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 286 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$ignoreEnableFields.

◆ setIncludeDeleted()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setIncludeDeleted (   $includeDeleted)

Sets the flag if the query should return objects that are deleted.

Parameters
bool$includeDeleted
Returns
QuerySettingsInterface

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 337 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$includeDeleted.

◆ setLanguageMode()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setLanguageMode (   $languageMode = '')
Parameters
string$languageModeNULL, "content_fallback", "strict" or "ignore"
Returns
QuerySettingsInterface instance of $this to allow method chaining

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 224 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$languageMode.

◆ setLanguageOverlayMode()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setLanguageOverlayMode (   $languageOverlayMode = FALSE)
Parameters
mixed$languageOverlayModeTRUE, FALSE or "hideNonTranslated"
Returns
QuerySettingsInterface instance of $this to allow method chaining

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 207 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$languageOverlayMode.

◆ setLanguageUid()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setLanguageUid (   $languageUid)

◆ setRespectStoragePage()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setRespectStoragePage (   $respectStoragePage)

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

Parameters
bool$respectStoragePageIf TRUE the storage page ID will be determined and the statement will be extended accordingly.
Returns
QuerySettingsInterface

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 150 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$respectStoragePage.

◆ setRespectSysLanguage()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setRespectSysLanguage (   $respectSysLanguage)
Parameters
bool$respectSysLanguageTRUE if TYPO3 language settings are to be applied
Returns
QuerySettingsInterface

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 190 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$respectSysLanguage.

◆ setReturnRawQueryResult()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setReturnRawQueryResult (   $returnRawQueryResult)

Sets the state, if the QueryResult should be returned unmapped.

Parameters
bool$returnRawQueryResultTRUE, if the QueryResult should be returned unmapped; otherwise FALSE.
Returns
QuerySettingsInterface
Deprecated:
since Extbase 6.2, will be removed two versions later. Please use argument in query->execute() instead.

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 358 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$returnRawQueryResult, and TYPO3\CMS\Core\Utility\GeneralUtility\logDeprecatedFunction().

◆ setStoragePageIds()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setStoragePageIds ( array  $storagePageIds)

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

Parameters
array$storagePageIdsIf given the storage page IDs will be determined and the statement will be extended accordingly.
Returns
QuerySettingsInterface

Implements TYPO3\CMS\Extbase\Persistence\Generic\QuerySettingsInterface.

Definition at line 171 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$storagePageIds.

◆ setSysLanguageUid()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::setSysLanguageUid (   $sysLanguageUid)

Sets the language uid for the language overlay.

Parameters
int$sysLanguageUidlanguage uid for the language overlay
Returns
QuerySettingsInterface instance of $this to allow method chaining
Deprecated:
since Extbase 6.2, will be removed two versions later. Use setLanguageUid() instead.

Definition at line 260 of file Typo3QuerySettings.php.

References TYPO3\CMS\Core\Utility\GeneralUtility\logDeprecatedFunction(), and TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\setLanguageUid().

◆ usePreparedStatement()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::usePreparedStatement (   $usePreparedStatement)
Parameters
bool$usePreparedStatement
Returns
QuerySettingsInterface

Definition at line 379 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$usePreparedStatement.

◆ useQueryCache()

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::useQueryCache (   $useQueryCache)
Parameters
bool$useQueryCache
Returns
QuerySettingsInterface

Definition at line 395 of file Typo3QuerySettings.php.

References TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings\$useQueryCache.

Member Data Documentation

◆ $enableFieldsToBeIgnored

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$enableFieldsToBeIgnored = array()
protected

◆ $ignoreEnableFields

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$ignoreEnableFields = FALSE
protected

◆ $includeDeleted

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$includeDeleted = FALSE
protected

◆ $languageMode

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$languageMode = NULL
protected

◆ $languageOverlayMode

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$languageOverlayMode = TRUE
protected

◆ $languageUid

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$languageUid = 0
protected

◆ $respectStoragePage

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$respectStoragePage = TRUE
protected

◆ $respectSysLanguage

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$respectSysLanguage = TRUE
protected

◆ $returnRawQueryResult

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$returnRawQueryResult = FALSE
protected

◆ $storagePageIds

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$storagePageIds = array()
protected

◆ $usePreparedStatement

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$usePreparedStatement = FALSE
protected

◆ $useQueryCache

TYPO3\CMS\Extbase\Persistence\Generic\Typo3QuerySettings::$useQueryCache = TRUE
protected