SingletonAsync class

Marks a class as an asynchronous singleton dependency.

The dependency must be resolved through CarburetorModule.getAsync. The instance is shared across all callers after the first resolution.

Inheritance
Implemented types

Constructors

SingletonAsync({bool lazy = true, bool weak = false})
Creates a SingletonAsync annotation.
const

Properties

async bool
Whether the provider factory is asynchronous.
finalinherited
hashCode int
The hash code for this object.
no setterinherited
lazy bool
Whether the singleton instance is created on first access rather than at module construction time.
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
singleton bool
Whether the dependency is managed as a singleton.
finalinherited
weak bool
Whether the singleton instance may be garbage-collected when no strong references to it remain.
finalinherited

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