LevitScopeMiddleware class abstract
Interface for observing and intercepting LevitScope lifecycle events.
Implement this interface to create middleware for logging, profiling, or custom lifecycle management.
Constructors
- LevitScopeMiddleware()
-
Creates a LevitScopeMiddleware.
const
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- 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
-
onDependencyCreate<
S> (S builder(), LevitScope scope, String key, LevitDependency info) → S Function() - Intercepts the instantiation logic of a dependency.
-
onDependencyDelete(
int scopeId, String scopeName, String key, LevitDependency info, {required String source, int? parentScopeId}) → void - Called when a dependency is removed.
-
onDependencyInit<
S> (void onInit(), S instance, LevitScope scope, String key, LevitDependency info) → void Function() -
Intercepts the
onInitcall of a dependency. -
onDependencyRegister(
int scopeId, String scopeName, String key, LevitDependency info, {required String source, int? parentScopeId}) → void - Called when a dependency matches a registration request.
-
onDependencyResolve(
int scopeId, String scopeName, String key, LevitDependency info, {required String source, int? parentScopeId}) → void - Called when a dependency instance is resolved.
-
onScopeCreate(
int scopeId, String scopeName, int? parentScopeId) → void - Called when a new LevitScope is created.
-
onScopeDispose(
int scopeId, String scopeName) → void - Called when a LevitScope is disposed.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited