BeforeFlexFormDataStructureParsedEvent implements StoppableEventInterface

FinalYes

Listeners to this event are able to specify a flex form data structure that corresponds to a given identifier.

Listeners should call ->setDataStructure() to set the data structure (this can either be a resolved data structure string, a "FILE:" reference or a fully parsed data structure as array) or ignore the event to allow other listeners to set it. Do not set an empty array or string as this will immediately stop event propagation!

See the note on FlexFormTools regarding the schema of $dataStructure.

Table of Contents

Interfaces

StoppableEventInterface

Methods

__construct()  : mixed
getDataStructure()  : array<string|int, mixed>|string|null
Returns the current data structure, which will always be `null` for listeners, since the event propagation is stopped as soon as a listener sets a data structure.
getIdentifier()  : array<string|int, mixed>
isPropagationStopped()  : bool
setDataStructure()  : void
Allows to either set an already parsed data structure as `array`, a file reference or the XML structure as `string`. Setting a data structure will immediately stop propagation. Avoid setting this parameter to an empty array or string as this will also stop propagation.

Methods

__construct()

public __construct(array<string|int, mixed> $identifier) : mixed
Parameters
$identifier : array<string|int, mixed>

getDataStructure()

Returns the current data structure, which will always be `null` for listeners, since the event propagation is stopped as soon as a listener sets a data structure.

public getDataStructure() : array<string|int, mixed>|string|null
Return values
array<string|int, mixed>|string|null

getIdentifier()

public getIdentifier() : array<string|int, mixed>
Return values
array<string|int, mixed>

isPropagationStopped()

public isPropagationStopped() : bool
Return values
bool

setDataStructure()

Allows to either set an already parsed data structure as `array`, a file reference or the XML structure as `string`. Setting a data structure will immediately stop propagation. Avoid setting this parameter to an empty array or string as this will also stop propagation.

public setDataStructure(array<string|int, mixed>|string $dataStructure) : void
Parameters
$dataStructure : array<string|int, mixed>|string

        
On this page

Search results