%ZHSLIB.Context.Manager
class %ZHSLIB.Context.Manager extends %Library.RegisteredObject
Property Inventory (Including Private)
Method Inventory (Including Private)
- %OnNew()
- BootstrapMappings()
- CheckForService()
- FindNamedInstance()
- GetInitializedNamespaces()
- GetService()
- GetServices()
- GetUpdateIndex()
- Initialize()
- Instance()
- RegisterNamedInstance()
- RegisterService()
- SetInitializedNamespaces()
- SetServices()
- SetUpdateIndex()
Parameters
parameter ContextNode = ^|"HSLIB"|HSContext;
Properties (Including Private)
property InitializedNamespaces [ Private , MultiDimensional ];
Array of namespace names for which services have been initialized
Property methods: InitializedNamespacesDisplayToLogical(), InitializedNamespacesGet(), InitializedNamespacesIsValid(), InitializedNamespacesLogicalToDisplay(), InitializedNamespacesLogicalToOdbc(), InitializedNamespacesNormalize(), InitializedNamespacesSet()
property NamedInstances [ Private , MultiDimensional ];
Non-singleton services registered for this process, subscripted by instance-key and namespace.
Property methods: NamedInstancesDisplayToLogical(), NamedInstancesGet(), NamedInstancesIsValid(), NamedInstancesLogicalToDisplay(), NamedInstancesLogicalToOdbc(), NamedInstancesNormalize(), NamedInstancesSet()
property Services [ Private , MultiDimensional ];
Services available for this process, subscripted by service name and version (and, optionally, namespace)
Property methods: ServicesDisplayToLogical(), ServicesGet(), ServicesIsValid(), ServicesLogicalToDisplay(), ServicesLogicalToOdbc(), ServicesNormalize(), ServicesSet()
property UpdateIndex as %Integer [ Private , InitialExpression = 0 ];
Time at which this instance had the latest version of services available
Property methods: UpdateIndexDisplayToLogical(), UpdateIndexGet(), UpdateIndexIsValid(), UpdateIndexLogicalToDisplay(), UpdateIndexNormalize(), UpdateIndexSet()
Methods (Including Private)
final method %OnNew() as %Status [ Language = objectscript ]
Starts all services defined in the current namespace
classmethod BootstrapMappings(pMapFromDatabase As %String = "HSLIB") [ Language = objectscript ]
Create package mappings for %SYSTEM.Context.HealthShare.* in %ALL
private method CheckForService(pServiceKey As %String, pMajorVersion As %Integer, pMinimumMinorVersion As %Integer) as %ZHSLIB.Context.ServiceBase [ Language = objectscript ]
Internal helper method for GetService(). Returns a service matching
the provided parameters if found. If not, returns null oref.
method FindNamedInstance(pInstanceKey As %String, pNamespace As %String = $Namespace) as %ZHSLIB.Context.NamedInstanceBase [ Language = objectscript ]
Named Instances are non-singleton instances of a service within a namespace. This supports multiple instances of the same service
with different configurations running in the same namespace. HS.FHIRService.Service is an example as a single namespace can support
multiple FHIR endpoints with different FHIR versions.
private method GetInitializedNamespaces(Output pInitializedNamespaces) [ Language = objectscript ]
method GetService(pServiceKey As %String, pMajorVersion As %Integer, UNUSED="", pMinimumMinorVersion As %Integer = 0) as %ZHSLIB.Context.ServiceBase [ Language = objectscript ]
Returns a per-process service instance matching the following parameters:
- Service key = composite key built from pServiceKey and pInstanceName
- Service major version = pMajorVersion
- Service minor version >= pMinimumMinorVersion
- Service patch version = latest available
private method GetServices(Output pServices) [ Language = objectscript ]
private method GetUpdateIndex() as %Integer [ Language = objectscript ]
private method Initialize() [ Language = objectscript ]
Initializes services for the current namespace
classmethod Instance() as %ZHSLIB.Context.Manager [ Language = objectscript ]
Returns the per-process instance of this class
method RegisterNamedInstance(pServiceInstance As %ZHSLIB.Context.NamedInstanceBase, pInstanceKey As %String, pNamespace As %String = $Namespace) [ Language = objectscript ]
Named Instances are non-singleton instances of a service within a namespace. This supports multiple instances of the same service
with different configurations running in the same namespace. HS.FHIRService.Service is an example as a single namespace can support
multiple FHIR endpoints with different FHIR versions.
method RegisterService(pServiceInstance As %ZHSLIB.Context.ServiceBase, pNamespace As %String = "") [ Language = objectscript ]
Adds a service to the Service property using the ServiceKey and ServiceVersion in pServiceInstance.
May be namespace-specific (if pNamespace is specified), or instance-wide (if not).
private method SetInitializedNamespaces(ByRef pInitializedNamespaces) [ Language = objectscript ]
private method SetServices(ByRef pServices) [ Language = objectscript ]
private method SetUpdateIndex(pUpdateIndex As %Integer) [ Language = objectscript ]
Inherited Members
Inherited Methods (Including Private)
- %AddToSaveSet()
- %ClassIsLatestVersion()
- %ClassName()
- %ConstructClone()
- %ConstructCloneInit()
- %DispatchClassMethod()
- %DispatchGetModified()
- %DispatchGetProperty()
- %DispatchMethod()
- %DispatchSetModified()
- %DispatchSetMultidimProperty()
- %DispatchSetProperty()
- %Extends()
- %GetParameter()
- %IsA()
- %IsModified()
- %New()
- %NormalizeObject()
- %ObjectModified()
- %OnAddToSaveSet()
- %OnClose()
- %OnConstructClone()
- %OnValidateObject()
- %OriginalNamespace()
- %PackageName()
- %RemoveFromSaveSet()
- %SerializeObject()
- %SetModified()
- %ValidateObject()