Reflection Processor

TypoScript wrapper for Reflection Service. Maps data to a simple array structure, based on the TCA configuration of the table. Also resolves all TCA-relations to other tables. The strength lies in the fast loading of already existing structures, especially when using Ajax requests or headless systems.

Parameter Description
buildingConfiguration Contains e.g. instructions for the preparation of files and images (see Example Case).
debug var_dumps information which elements would be reflected.
maxDepth The maximum depth at which related elements are loaded (default is 8).
replace Replace the current data with the result of this DataProcessor
row If set, data content of row would be reflected, otherwise the current data would be used (default).
rows

Same behavior as using row, with one important difference: To guard against endless recursions and unperformant reloading of rows, the Reflection service uses an internal store for previously loaded elements. This is store is accessable for all elements in rows. This is a huge performance gain, especially when the elements in rows are often related to the same elements.

table Tablename which should be mapped (default: tt_content) (see Example Case).
tableColumnBlacklist

List of table columns which should be blacklisted (wildcards like "*" and "?" are useable) (see Example Case).

tableColumnRemapping List of table columns to be renamed (see Example Case)
tableColumnRemoveablePrefixes List of table columns where the prefix should be removed (see Example Case)
tableColumnWhitelist List of table columns which should be whitelisted (wildcards like "*" and "?" are useable) (see Example Case)

Example Case

Assuming we have want to reflect of an slider element with the following table column / TCA structure:

  • CType "slider" (located in table tt_content)

    • all default tt_content fields (header, categories, space_before_class, etc ...)
    • tx_myextension_duration (input, with eval "int")
    • tx_myextension_slides (IRRE relation to table tx_myextension_slides)

      • image (FAL with the croppings for desktop, medium, tablet, mobile)
      • headline (input)
      • descrition (RTE text)
      • link (input with link wizard)
      • categories (category tree)

Output before reflection

[
   'data' => [
      'uid' => 123,
      'pid' => 345,
      'categories' => 4,
      'header' => 'my slider',
      'tx_myextension_duration' => 8000,
      'tx_myextension_slides' = 3
      // ... many other system related columns
   ],
   'current' => null
]
Copied!