IgnoreDependency class
Annotation used to indicate that a dependency should be ignored by the dependency injection system.
The IgnoreDependency annotation can be applied to a class/factory to specify that it should not be included in the dependency injection container. By default, the dependency is ignored in both the production and test dependency injection containers. The inLocator and inTestLocator parameters can be used to control whether the dependency should be included in the production and test dependency injection containers respectively.
Example usage:
@IgnoreDependency(inLocator: false)
class MyService {
// ...
}
Constructors
- IgnoreDependency({bool inLocator = true, bool inTestLocator = true})
-
const
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- inLocator → bool
-
final
- inTestLocator → bool
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
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