Skip to main content

HS.BulkFHIR.ExportManager

class HS.BulkFHIR.ExportManager extends HS.BulkFHIR.Util

Method Inventory

Parameters

parameter errorType = error;

Methods

classmethod AddError(pSession As HS.BulkFHIR.Session, error As %DynamicObject, query As %String = "")
@API API for a fetch adapter to add an error/warning to the result set for a specified session. This will not trigger a fatal error and termination, it will make the error available for the client to see along with the successfully added resources. @Input pSession the session being processed @Input error FHIR OperationOutcome error to add to the operation's error result set @Input query (optional) the fetch adapter may specify this error was added from a specific query. This must be provided if the adapter wants to take advantage of the IsQueryComplete API in this class.
classmethod AddResource(pSession As HS.BulkFHIR.Session, rsrc As %DynamicObject, query As %String = "")
@API API for a fetch adapter to add a resource to the result set for a specified session @Input pSession Session object of the session being processed @Input rsrc FHIR resource to add to the operation's result set @Input query (optional) the fetch adapter may specify this resource was added from a specific query. This must be provided if the adapter wants to take advantage of the IsQueryComplete API in this class.
classmethod CheckFilters(session As HS.BulkFHIR.Session, rsrc As %DynamicObject) as %Boolean
Evaluate the resource content against any of a number of filters that are persisted on the session object.
classmethod CompleteQuery(pSession As HS.BulkFHIR.Session, pQuery As %String)
@API API for the fetch adapter to register a query as complete. Once a query is complete, the IsQueryComplete API will return true. The fetch adapter can use that to determine whether it needs to re-run a query if the job is paused and restarted. @Input pSession the session being processed @Input pQuery The query string to be marked as complete.
classmethod GetStream(pSession As HS.BulkFHIR.Session, pType As %String) as %Stream.FileCharacter
@BFC_Internal Using specified working_directory get existing or new buffer file for type (for this job)
classmethod GetStreamLine(pStream As %Stream.FileCharacter, Output pLine As %String, Output pTempStream As %Stream.TmpCharacter)
@BFC_Internal using the ndjson file get the object into either pLine or pTempStream (depending on size)
classmethod IsQueryComplete(Output pLockManager As %ZHSLIB.LockManager, pSession As HS.BulkFHIR.Session, pQuery As %String) as %Boolean
@API API for the fetch adapter to check whether a query has been completed. The ExportManager buffers resources before delivering them to the storage adapter, so fetch adapters should make use of this method rather than doing their own bookkeeping. This will prevent queries from being re-run if the system goes down during an operation. @Output pLockManager take out a lock on the queryPath to ensure another process is not adding it @Input pSession the session being processed @Input pQuery The query string which may or may not be complete
classmethod IsResourceAdded(Output pLockManager As %ZHSLIB.LockManager, pSession As HS.BulkFHIR.Session, pType As %String, pID As %String) as %Boolean
@API API to check whether a resource has been successfully added. The ExportManager buffers resources before delivering them to the storage adapter, so fetch adapters should make use of this method rather than doing their own bookkeeping. This will prevent resources from being lost if the system goes down during an operation. @Output pLockManager take out a lock on the resource to ensure only a single process is adding it @Input pSession session being processed @Input pType Resource type being looked up @Input pID id of the resource being looked up

Inherited Members

Inherited Methods

FeedbackOpens in a new tab