FpDI class
Unified Dependency Injection Manager for Flutter Prakash (FP).
Simplifies DI configuration, module registration, and scope resets across apps.
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
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
isRegistered<
T extends Object> ({String? instanceName}) → bool -
Checks if type
Tis registered. -
registerFactory<
T extends Object> (T factoryFunc(), {String? instanceName}) → void - Register a factory (creates new instance on each call).
-
registerLazySingleton<
T extends Object> (T factoryFunc(), {String? instanceName}) → void - Register a lazy singleton instance.
-
registerSingleton<
T extends Object> (T instance, {String? instanceName}) → void - Register a ready-to-use singleton instance.
-
reset(
{bool dispose = true}) → Future< void> - Resets the DI container (useful for unit tests or user logouts).