flutter_service_container library
Provide useful widgets for service_container package.
Classes
- ConsoleColor
- Console ansi color helper
- ConsoleColors
- ConsoleLogPrinter
- The default LogPrinter for console
- ContainerConfigure
- Service container configuration.
- DeveloperLogPrinter
- Forwards logs to the dart:developer log() API.
- IAsyncDisposable
- Used to release resources asynchronously.
- IDisposable
- Indicates the interface for which resources need to be released.
- IServiceProvider
- Service provider interface
- IServiceScope
- Service scope
- IServiceScopeFactory
- Service Scope Factory
- LogPrinter
- support to print logs that published by dart:logging package.
-
ScopedDescriptor<
T> - Scoped descriptor
-
ScopedFutureDescriptor<
T> - Scoped future descriptor that supports asynchronous initialization.
- ServiceConsumer
- A widget that consumes services
-
ServiceDescriptor<
T> - Describe a service
- ServiceProvider
- Represents the root service provider, it's a IServiceScopeFactory too.
- Services
- Share the IServiceProvider for child widgets.
- ServicesRoot
- Provide a root provider for the child widget.
- ServicesScope
- Provide a scope for the child widget.
-
SingletonDescriptor<
T> - Singleton descriptor
-
SingletonFutureDescriptor<
T> - Singleton future descriptor that supports asynchronous initialization.
-
TransientDescriptor<
T> - Transient descriptor
-
TransientFutureDescriptor<
T> - Transient future descriptor that supports asynchronous initialization.
Enums
- ServiceLifeTime
- Service life-time
Extensions
- ConsoleColorExtensions on ConsoleColor
- Provide additional methods
- FlutterContainerConfigure on ContainerConfigure
- ServiceContainerLogging on ContainerConfigure
- Config service container's logging.
- ServiceProviderExtensions on IServiceProvider
- Extension methods for IServiceProvider
Constants
- containerConfigure → const ContainerConfigure
- A const instance of ContainerConfigure
Properties
-
$LogPrinter
↔ ServiceDescriptor<
LogPrinter> -
dart:logging package's log printer.
getter/setter pair
Typedefs
- ProviderWidgetBuilder = Widget Function(BuildContext context, IServiceProvider p)
- A widget builder
-
ServiceFactory<
T> = T Function(IServiceProvider p) - Service factory.