ServiceDescriptor class
Describes a service.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- implementationAlias → Type?
-
The type of the aliased service.
final
- implementationFactory → (Object Function(ServiceProvider sp)?)
-
The factory used to create the service.
final
- implementationInstance → Object?
-
The singleton instance of the service.
final
- isGenerated → bool
-
Indicates whether the implementation of the service is generated by
the dino generator or registered manually.
final
- lifetime → ServiceLifetime
-
The lifetime of the service.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- serviceType → Type
-
The type of the service used to resolve it.
final
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
-
alias<
TService extends Object, TImplementation extends Object> ([bool isGenerated = false]) → ServiceDescriptor -
Creates a transient service descriptor for the specified
TService
type implemented as an alias of the specifiedTImplementation
type.TImplementation
must implementTService
. -
factory<
TService extends Object> (ServiceLifetime lifetime, ServiceFactory< TService> factory, [bool isGenerated = false]) → ServiceDescriptor -
Creates a service descriptor for the specified
TService
type with specifiedlifetime
and implementationFactory. -
instance<
TService extends Object> (TService instance) → ServiceDescriptor -
Creates a singleton service descriptor for the specified
TService
type with specified implementationInstance.