Package-level declarations
Types
This annotation marks a ServiceKey type that is considered experimental. Its API may be changed or removed in future releases.
A Key type used in ServiceLocator. Will provide values of type T.
A basic service locator for storing common dependencies. ServiceLocator acts like a heterogeneous map, holding values of different types. The ServiceKey dictates which type will be accessed.
Functions
A convenience extension to fetch a singleton instance from the ServiceLocator using its reified type T as the key.
Fetches an item for key. If no provider has been registered, this will delegate to ServiceLocator.onMiss.
A convenience extension to fetch a singleton instance from the ServiceLocator using its reified type T as the key.
Fetches the item for key. If no provider has been registered, returns null. Does not invoke ServiceLocator.onMiss.