TYPO3 CMS  TYPO3_7-6
TYPO3\CMS\Backend\Form\Container\SingleFieldContainer Class Reference
Inheritance diagram for TYPO3\CMS\Backend\Form\Container\SingleFieldContainer:
TYPO3\CMS\Backend\Form\Container\AbstractContainer TYPO3\CMS\Backend\Form\AbstractNode TYPO3\CMS\Backend\Form\NodeInterface

Protected Member Functions

 arrayCompareComplex ($subjectArray, $searchArray, $type='')
 
 isAssociativeArray ($object)
 
 getBackendUserAuthentication ()
 
 getLanguageService ()
 
- Protected Member Functions inherited from TYPO3\CMS\Backend\Form\Container\AbstractContainer
 explodeSingleFieldShowItemConfiguration ($field)
 
 renderTabMenu (array $menuItems, $domId, $defaultTabIndex=1)
 
 previewFieldValue ($value, $config, $field='')
 
- Protected Member Functions inherited from TYPO3\CMS\Backend\Form\AbstractNode
 initializeResultArray ()
 
 mergeChildReturnIntoExistingResult (array $existing, array $childReturn)
 
 getValidationDataAsDataAttribute (array $config)
 
 getValidationDataAsJsonString (array $config)
 

Additional Inherited Members

- Public Member Functions inherited from TYPO3\CMS\Backend\Form\Container\AbstractContainer
 __construct (NodeFactory $nodeFactory, array $data)
 
- Public Member Functions inherited from TYPO3\CMS\Backend\Form\AbstractNode
 __construct (NodeFactory $nodeFactory, array $data)
 
 render ()
 
- Protected Attributes inherited from TYPO3\CMS\Backend\Form\Container\AbstractContainer
 $nodeFactory
 
- Protected Attributes inherited from TYPO3\CMS\Backend\Form\AbstractNode
 $data = []
 

Detailed Description

Container around a "single field".

This container is the last one in the chain before processing is handed over to single element classes. If a single field is of type flex or inline, it however creates FlexFormEntryContainer or InlineControlContainer.

The container does various checks and processing for a given single fields, for example it resolves display conditions and the HTML to compare different languages.

Definition at line 38 of file SingleFieldContainer.php.

Member Function Documentation

◆ arrayCompareComplex()

TYPO3\CMS\Backend\Form\Container\SingleFieldContainer::arrayCompareComplex (   $subjectArray,
  $searchArray,
  $type = '' 
)
protected

Handles complex comparison requests on an array. A request could look like the following:

$searchArray = array( 'AND' => array( 'key1' => 'value1', 'key2' => 'value2', 'OR' => array( 'subarray' => array( 'subkey' => 'subvalue' ), 'key3' => 'value3', 'key4' => 'value4' ) ) );

It is possible to use the array keys 'AND.1', 'AND.2', etc. to prevent overwriting the sub-array. It could be necessary, if you use complex comparisons.

The example above means, key1 AND key2 (and their values) have to match with the $subjectArray and additional one OR key3 or key4 have to meet the same condition. It is also possible to compare parts of a sub-array (e.g. "subarray"), so this function recurses down one level in that sub-array.

Parameters
array$subjectArrayThe array to search in
array$searchArrayThe array with keys and values to search for
string$typeUse 'AND' or 'OR' for comparison
Returns
bool The result of the comparison

Definition at line 560 of file SingleFieldContainer.php.

References TYPO3\CMS\Backend\Form\Container\SingleFieldContainer\isAssociativeArray().

◆ getBackendUserAuthentication()

TYPO3\CMS\Backend\Form\Container\SingleFieldContainer::getBackendUserAuthentication ( )
protected
Returns
BackendUserAuthentication

Definition at line 625 of file SingleFieldContainer.php.

References $GLOBALS.

◆ getLanguageService()

TYPO3\CMS\Backend\Form\Container\SingleFieldContainer::getLanguageService ( )
protected
Returns
LanguageService

Definition at line 633 of file SingleFieldContainer.php.

References $GLOBALS.

◆ isAssociativeArray()

TYPO3\CMS\Backend\Form\Container\SingleFieldContainer::isAssociativeArray (   $object)
protected

Checks whether an object is an associative array.

Parameters
mixed$objectThe object to be checked
Returns
bool Returns TRUE, if the object is an associative array

Definition at line 617 of file SingleFieldContainer.php.

Referenced by TYPO3\CMS\Backend\Form\Container\SingleFieldContainer\arrayCompareComplex().