resolveAll<T> function

List<T> resolveAll<T>()

This function resolves a service determined by the type T.

Throws a InjectionContextNotInitialized exception, if the injection context is not started.

Implementation

List<T> resolveAll<T>() {
  var services = List<T>();

  _ContextCollection.shared.profiles.values.forEach((context) => services.addAll(context.resolveAll<T>()));

  return services;
}