ServiceProviderInterface
A service provider provides entries to a container. Inspired by: https://github.com/container-interop/service-provider/blob/v0.4.0/src/ServiceProviderInterface.php
Table of Contents
Methods
- getExtensions() : array<string|int, callable>
- Returns a list of all container entries extended by this service provider.
- getFactories() : array<string|int, callable>
- Returns a list of all container entries registered by this service provider.
Methods
getExtensions()
Returns a list of all container entries extended by this service provider.
    public
                    getExtensions() : array<string|int, callable>
    - the key is the entry name
- the value is a callable that will return the modified entry
Callables have the following signature: function(Psr\Container\ContainerInterface $container, $previous) or function(Psr\Container\ContainerInterface $container, $previous = null)
About factories parameters:
- the container (instance of Psr\Container\ContainerInterface)
- the entry to be extended. If the entry to be extended does not exist and the parameter is nullable, nullwill be passed.
Return values
array<string|int, callable>getFactories()
Returns a list of all container entries registered by this service provider.
    public
                    getFactories() : array<string|int, callable>
    - the key is the entry name
- the value is a callable that will return the entry, aka the factory
Factories have the following signature: function(\Psr\Container\ContainerInterface $container)