Skip to content

Extension points

phil/instant-messenger-bundle

What an application adds or extends. The services and handles are phil/instant-messenger's.

The application's own services

An enum of the application's implementing Phil\InstantMessenger\MessengerType is accepted wherever services are named: in the types of HandleType and of HandleOfType, before or after the international ones, as an enum class, a case, an EnumSet or a list of these. Its choices are named by their case's name; messenger_label gives the same — see Forms and validation.

Forms and validation

PointHow
The services offered, and their orderThe types option of HandleType
The services acceptedThe types of HandleOfType; its message and the code HandleOfType::NOT_ACCEPTED_ERROR
More than the field doesA form type extension of the application's on HandleType

Storage and Twig

PointHow
Where a handle is keptTwo columns the application maps — the service with its own enum, the canonical handle — read back with Handle::fromCanonical()
How a handle is shownmessenger_display, messenger_link and messenger_label — see Twig