enum classafIoc::ServiceLifecycle
sys::Obj sys::Enum afIoc::ServiceLifecycle
@
Serializable { simple=true }
Used by ServiceStat to define the lifecycle state of a service. A service lifecycle looks like:
DEFINED - the service is defined in a module || \/ VIRTUAL - a proxy has been created and the service may be injected || \/ CREATED - the implementation has been created and the service is live
The service implementation is created on demand when methods on the proxy are called.
Note that if a service does not have a proxy, the VIRTUAL
stage is skipped.
@since 1.2.0
- BUILTIN
const static ServiceLifecycle BUILTIN := ...
Builtin services are internal IoC services. They exist before the Registry is constructed.
- CREATED
const static ServiceLifecycle CREATED := ...
The service implementation has been created. It lives!
- DEFINED
const static ServiceLifecycle DEFINED := ...
The service is defined in a module, but has not yet been referenced.
- VIRTUAL
const static ServiceLifecycle VIRTUAL := ...
A proxy has been created for the service and may be injected into other services. No methods of the proxy have been invoked and the implementation does yet not exist.
- fromStr
static new fromStr(Str name, Bool checked := true)
Return the ServiceLifecycle instance for the specified name. If not a valid name and checked is false return null, otherwise throw ParseErr.
- vals
const static ServiceLifecycle[] vals := ...
List of ServiceLifecycle values indexed by ordinal