LazyContextRepository
class LazyContextRepository implements ContextRepositoryInterface (View source)
Provides a context repository which uses context provider services.
Properties
| protected string[] | $contextProviderServiceIDs | The set of available context providers service IDs. |
|
| protected ContainerInterface | $container | The service container. |
|
| protected ContextInterface[] | $contexts | The statically cached contexts. |
Methods
Constructs a LazyContextRepository object.
Gets runtime context values for the given context IDs.
Gets all available contexts for the purposes of configuration.
Details
__construct(ContainerInterface $container, array $context_provider_service_ids)
Constructs a LazyContextRepository object.
ContextInterface[]
getRuntimeContexts(array $context_ids)
Gets runtime context values for the given context IDs.
Given that context providers might not return contexts for the given context IDs, it is also not guaranteed that the context repository returns contexts for all specified IDs.
ContextInterface[]
getAvailableContexts()
Gets all available contexts for the purposes of configuration.