LazySingleton class final

Annotation used to mark a class as a lazy singleton.

A lazy singleton is a class that is instantiated only once and its instance is lazily created when it is first accessed.

Usage:

@LazySingleton()
class MyClass {
  // class implementation
}

Note: When this annotation is used, dependencies are automatically resolved and injected.

Constructors

LazySingleton()
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
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited