InjectorScope class abstract
An class used to access instances of an specified type without knowing the concrete type or value.
Only one should exist per scope, and if more than one is being used in the
program, they should NOT mix InjectableConsumer
s. Doing so is an Error!
Constructors
-
InjectorScope.debug(Map<
Type, Object> injectedValues) -
Create an InjectorScope which contains the specified
injectedValues
factory
Properties
-
children
→ Iterable<
InjectorScope> -
The child InjectorScopes
no setter
- debugLabel → String
-
The debugLabel for this scope. The root is labeled
root
and other scopes are labelled with the hashCode if no label was specified on the InjectorScopeBuilder.no setter - hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
checkContains(
Type type) → void -
Assert that this InjectorScope or one of it's parents can inject
type
. -
checkContainsAll(
List< Type> types) → void -
Assert that this InjectorScope can inject every Type in
types
. -
get<
T> () → T -
Get the injected instance of type
T
-
getAllInjected(
) → List - Returns every value that was injected at least once. Useful for disposal of objects.
-
getUntyped(
Type t) → dynamic -
Get the instance of type
t
, without any static type safety. -
injectableTypes(
) → List< Type> - The Types that this InjectorScope can inject.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited