SpotService<T> class

Represents a service that can be located type = the type of service (factory or singleton) locator = the function to instantiate the type The locator function is called lazily the first time the dependency is requested

Constructors

SpotService(SpotType type, SpotGetter<T>? locator, Type targetType, {SpotAsyncGetter<T>? asyncLocator})

Properties

asyncLocator SpotAsyncGetter<T>?
final
hashCode int
The hash code for this object.
no setterinherited
instance ↔ T?
getter/setter pair
locator SpotGetter<T>?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
targetType Type
final
type SpotType
final

Methods

dispose() → void
locate() → T
locateAsync() Future<T>
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