withDependencies<T extends Object> static method

InjectableFactory withDependencies<T extends Object>(
  1. DependencyData dependencyData,
  2. InjectableInstanceCreatorWithDependencies<T> creator, {
  3. InjectableScope? scope,
})

Creates an InjectableFactory for a type that has dependencies.

  • dependencyData: The description of the required dependencies.
  • creator: A function that takes Dependencies and returns an instance of T.
  • scope: The optional InjectableScope for the created instance.

Implementation

static InjectableFactory withDependencies<T extends Object>(DependencyData dependencyData, InjectableInstanceCreatorWithDependencies<T> creator, {InjectableScope? scope}) =>
    InjectableFactory._(buildsType: T, creator: creator, scope: scope, dependencyData: dependencyData);