Build the container config from legacy DCA syntax.

Abstract base class for an data definition builder. To use it, implement the method build() and register the class to the event dispatcher.

 Methods

{@inheritdoc}

build(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container, \ContaoCommunityAlliance\DcGeneral\Factory\Event\BuildDataDefinitionEvent $event) 

Parameters

$container

$event

Test if a data provider name is a special name.

isSpecialName(string $name) : bool

Parameters

$name

string

The name to test.

Returns

bool

Load all additional definitions, like naming of parent data provider etc.

loadAdditionalDefinitions(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container) : void

Parameters

$container

\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface

The container where the data shall be stored.

Parse and build the backend view definition for the old Contao2 backend view.

parseBackendView(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container) : void
This method expects to find an instance of Contao2BackendViewDefinitionInterface in the container.

Parameters

$container

\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface

The container where the data shall be stored.

Exceptions

\ContaoCommunityAlliance\DcGeneral\Exception\DcGeneralInvalidArgumentException If the stored definition in the container is of invalid type.

Ensure that the basic configuration is set in the definition.

parseBasicDefinition(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container) : void

Parameters

$container

\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface

The container where the data shall be stored.

Parse all class names for view, controller and callback class.

parseClassNames(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container) : void

Parameters

$container

\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface

The container where the data shall be stored.

Exceptions

\ContaoCommunityAlliance\DcGeneral\Exception\DcGeneralInvalidArgumentException When the container is of invalid type.

Parse the conditions for model relationships from the definition.

parseConditions(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container) : void
This includes root entry filters, parent child relationship.

Parameters

$container

\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface

The container where the data shall be stored.

Exceptions

\ContaoCommunityAlliance\DcGeneral\Exception\DcGeneralRuntimeException If any information is missing or invalid.

This method parses all data provider related information from Contao legacy data container arrays.

parseDataProvider(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container) : void
SuppressWarnings (PHPMD.LongVariable)

Parameters

$container

\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface

The container where the data shall be stored.

Parse the sorting part of listing configuration.

parseListLabel(\ContaoCommunityAlliance\DcGeneral\DataDefinition\Definition\View\ListingConfigInterface $listing) : void

Parameters

Parse the listing configuration.

parseListing(\ContaoCommunityAlliance\DcGeneral\Contao\DataDefinition\Definition\Contao2BackendViewDefinitionInterface $view) : void

Parse the palette information.

parsePalettes(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container) : void

Parameters

$container

\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface

The container where the data shall be stored.

Parse the root condition.

parseParentChildConditions(\ContaoCommunityAlliance\DcGeneral\DataDefinition\Definition\ModelRelationshipDefinitionInterface $definition) : void

Parse the root condition.

parseRootCondition(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container, \ContaoCommunityAlliance\DcGeneral\DataDefinition\Definition\ModelRelationshipDefinitionInterface $definition) : void

Parameters

$container

\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface

The container where the data shall be stored.

Exceptions

\ContaoCommunityAlliance\DcGeneral\Exception\DcGeneralRuntimeException If no root data provider is defined.

Parse a single data provider information and prepare the definition object for it.

parseSingleDataProvider(\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface $container, \ContaoCommunityAlliance\DcGeneral\DataDefinition\Definition\DataProviderDefinitionInterface $providers, array $information, string|null $name) : \ContaoCommunityAlliance\DcGeneral\Contao\Dca\ContaoDataProviderInformation | null

Parameters

$container

\ContaoCommunityAlliance\DcGeneral\DataDefinition\ContainerInterface

The container where the data shall be stored.

$information

array

The information for the data provider to be parsed.

$name

stringnull

The name of the data provider to be used within the container.

Returns

 Constants

 

PRIORITY

PRIORITY