Skip to main content

HS.IHE.XDM.PortableMediaCreator.Process

persistent class HS.IHE.XDM.PortableMediaCreator.Process extends Ens.BusinessProcess, HS.Util.BaseHost, HS.IHE.XDSb.DocumentSource.Abstract

SQL Table Name: HS_IHE_XDM_PortableMediaCreator.Process

IHE XDSb Document Source Actor Given a CDA stream extract relevant data and build ProvideAndRegister transaction

Property Inventory

Method Inventory

Parameters

parameter INVOCATION = Queue;
Inherited description: 2 modes: Queue, InProc
parameter SETTINGS = PIXv3ConsumerOperations:Basic:selector?multiSelect=1&context={Ens.ContextSearch/ProductionItems?targets=1&productionName=@productionId},CustomProcessor:Basic,AssumeMinimal:Basic,ReadMe:Basic,HTMLHeader:Basic,HTMLFooter:Basic,PostCreationOperation:Basic:selector?multiSelect=1&context={Ens.ContextSearch/ProductionItems?targets=1&productionName=@productionId},ZipOperation::selector?multiSelect=1&context={Ens.ContextSearch/ProductionItems?targets=1&productionName=@productionId},MetadataTransform,DocumentTransform;
Inherited description: List of properties can be set as settings in the configuration file format is a comma separated list of property names

Properties

property AssumeMinimal as %Boolean [ InitialExpression = 1 ];
Assume XDS Minimal Metadata -- If set to true, will assume XDM is intended to comply with XDS Minimal Metadata Requirements instead of full XDS Metdata
Property methods: AssumeMinimalDisplayToLogical(), AssumeMinimalGet(), AssumeMinimalGetStored(), AssumeMinimalIsValid(), AssumeMinimalLogicalToDisplay(), AssumeMinimalNormalize(), AssumeMinimalSet()
property DocumentTransform as %String (MAXLEN = 255) [ InitialExpression = "IHE/XDSb/Version1/MetadataObject-to-Message.xsl" ];
See %HSHOME%/csp/xslt/IHE/XDSb/Version1/DocumentToDistributeDocumentSetOnMedia.xsl for an example
Property methods: DocumentTransformDisplayToLogical(), DocumentTransformGet(), DocumentTransformGetStored(), DocumentTransformIsValid(), DocumentTransformLogicalToDisplay(), DocumentTransformLogicalToOdbc(), DocumentTransformNormalize(), DocumentTransformSet()
property HTMLFooter as %String (MAXLEN = 2048);
Path to custom HTML footer (such as /pathtofile/footerfile.txt) for INDEX.HTM file in the XDM.
Property methods: HTMLFooterDisplayToLogical(), HTMLFooterGet(), HTMLFooterGetStored(), HTMLFooterIsValid(), HTMLFooterLogicalToDisplay(), HTMLFooterLogicalToOdbc(), HTMLFooterNormalize(), HTMLFooterSet()
property HTMLHeader as %String (MAXLEN = 2048);
Path to custom HTML header (such as /pathtofile/headerfile.txt) for INDEX.HTM file in the XDM.
Property methods: HTMLHeaderDisplayToLogical(), HTMLHeaderGet(), HTMLHeaderGetStored(), HTMLHeaderIsValid(), HTMLHeaderLogicalToDisplay(), HTMLHeaderLogicalToOdbc(), HTMLHeaderNormalize(), HTMLHeaderSet()
property MetadataTransform as %String (MAXLEN = 255) [ InitialExpression = "IHE/XDSb/Version1/Message-to-MetadataObject.xsl" ];
Property methods: MetadataTransformDisplayToLogical(), MetadataTransformGet(), MetadataTransformGetStored(), MetadataTransformIsValid(), MetadataTransformLogicalToDisplay(), MetadataTransformLogicalToOdbc(), MetadataTransformNormalize(), MetadataTransformSet()
property PIXv3ConsumerOperations as %String [ InitialExpression = "HS.IHE.PIXv3.Consumer.Operations" ];
The PIXv3 Consumer operation - if the patientId is not defined in the request use the sourceId and query the pix manager
Property methods: PIXv3ConsumerOperationsDisplayToLogical(), PIXv3ConsumerOperationsGet(), PIXv3ConsumerOperationsGetStored(), PIXv3ConsumerOperationsIsValid(), PIXv3ConsumerOperationsLogicalToDisplay(), PIXv3ConsumerOperationsLogicalToOdbc(), PIXv3ConsumerOperationsNormalize(), PIXv3ConsumerOperationsSet()
property PostCreationOperation as Ens.DataType.ConfigName [ InitialExpression = "HS.IHE.XDM.FileOutputOperation" ];
An optional operation to send the created XDM file
Property methods: PostCreationOperationDisplayToLogical(), PostCreationOperationGet(), PostCreationOperationGetStored(), PostCreationOperationIsValid(), PostCreationOperationLogicalToDisplay(), PostCreationOperationLogicalToOdbc(), PostCreationOperationNormalize(), PostCreationOperationParseConfigNameSpec(), PostCreationOperationSet()
property ReadMe as %String;
Path to Generic Readme file to insert into XDM (such as /pathtofile/file.txt), or override the GetReadMe method to customize this behavior.
Property methods: ReadMeDisplayToLogical(), ReadMeGet(), ReadMeGetStored(), ReadMeIsValid(), ReadMeLogicalToDisplay(), ReadMeLogicalToOdbc(), ReadMeNormalize(), ReadMeSet()
property ZipOperation as Ens.DataType.ConfigName;
Optionally create a zip file of the output - Operation to send message to be zipped
Property methods: ZipOperationDisplayToLogical(), ZipOperationGet(), ZipOperationGetStored(), ZipOperationIsValid(), ZipOperationLogicalToDisplay(), ZipOperationLogicalToOdbc(), ZipOperationNormalize(), ZipOperationParseConfigNameSpec(), ZipOperationSet()

Methods

method BuildDistributionSet(pRequest As HS.Message.IHE.XDM.DistributeDocumentSetRequest, Output pResponse As HS.Message.IHE.XDM.DistributeDocumentSetResponse) as %Status
Optionally define customization class by setting CustomProcessor to class name and define either method

Tracing in the methods with HSTRACECALLED, HSTRACECALLEDMIN, HSTRACECALLEDERROR
Call out to other business hosts using pHost.SendRequestAsync or pHost.SendRequest.Sync

BuildDistributionSet takes the inbound HS.Message.IHE.XDM.DistributeDocumentSetRequest and
  • Calls ValidateRequest
  • For each submission calls UpdateRequest
  • calls IndexAndHeaders
  • calls ZipOperation host if defined
  • calls PostCreationOperation host (if defined) with a new HS.Message.IHE.XDM.DistributeDocumentSetRequest
  • ClassMethod OnPreBuildDistributionSet(pHost As Ens.Host , Output pStopProcessing as %Boolean, pRequest As HS.Message.IHE.XDM.DistributeDocumentSetRequest, Output pResponse as HS.Message.IHE.XDM.DistributeDocumentSetResponse) as %Status()
  • if pStopProcessing is true processing will terminate with tSC (either ok or error).
  • Updates can be done to the DistributeDocumentSet object prior to any additional processing, such as providing necessary missing fields
  • ClassMethod OnPostBuildDistributionSet(pHost As Ens.Host, pRequest as HS.Message.IHE.XDM.DistributeDocumentSetRequest, pResponse as HS.Message.IHE.XDM.DistributeDocumentSetResponse) as %Status()
  • Additional processing can be done to the response, or the response itself can be updated
  • method ConvertToDistributeDocumentSet(pRequest, Output pNewRequest) as %Status
    method GetReadMe() as %Stream.FileCharacter
    Method for loading the README.TXT file contents in the root directory of the XDM. Override this method for more robust README.TXT file creation.
    This method accepts a HS.Message.IHE.XDM.DistributeDocumentSetRequest object as its input and will move the transformed metadata objects into files, transform CDA to HTML where possible and attach. Build and insert the index, the readme, and the header/footer. Returns a new HS.Message.IHE.XDM.DistributeDocumentSetResponse which contains the Files as a HS.Types.ZipResponse


    Note: all files in the XDM archive must have uppercase names and cannot exceed 8 characters + 3 character extension
    Examples
    • DOCUMENT.TXT = Correct
    • Document.txt = Incorrect - Not all uppercase
    • DOCUMENT.txt = Incorrect - Not all uppercase
    • DOCUMENT01.TXT = Incorrect - Exceeds 8 character limit for file name
    • DOCUMENT.TEXT = Incorrect - Exceeds 3 character limit for file extension
    Optionally define customization class by setting CustomProcessor to class name and define either method

    Tracing in the methods with HSTRACECALLED, HSTRACECALLEDMIN, HSTRACECALLEDERROR
    Call out to other business hosts using pHost.SendRequestAsync or pHost.SendRequest.Sync

    ClassMethod OnPreIndexAndHeaders(pHost As Ens.Host , Output pStopProcessing as %Boolean, pRequest As HS.Message.IHE.XDM.DistributeDocumentSetRequest) as %Status()
  • if pStopProcessing is true processing will terminate with tSC (either ok or error).
  • Updates can be done to the DistributeDocumentSet object prior to any additional processing, such as providing necessary missing fields
  • ClassMethod OnPostIndexAndHeaders(pHost As Ens.Host, pRequest as HS.Message.IHE.XDM.DistributeDocumentSetRequest) as %Status()
  • Additional processing can be done to the response, or the response itself can be updated
  • method IndexFooter(ByRef pIndexHTML As %Stream.FileCharacter, Args...)
    If HTMLFooter file is defined, this method will output that information. Otherwise, it will generate a generic HealthShare header. Override this method and pass in extra Args to customize the output for content specific settings.
    method IndexHeader(ByRef pIndexHTML As %Stream.FileCharacter, Args...)
    If HTMLHeader file is defined, this method will output that information. Otherwise, it will generate a generic HealthShare header. Override this method and pass in extra Args to customize the output for content specific settings.
    method OnInit() as %Status
    This user callback method is called via initConfig() from %OnNew() or in the case of SOAP Services from OnPreSOAP()
    method OnRequest(pRequest As %Library.Persistent, Output pResponse As %Library.Persistent) as %Status
    Inherited description: Handle a 'Request'
    method OnResponse(pRequest As Ens.Request, ByRef pResponse As Ens.Response, pCallrequest As Ens.Request, pCallresponse As Ens.Response, pCompletionKey As %String) as %Status
    OnResponse must be overridden here to avoid error upon response from async request.
    method UpdateRequest(pRequest As HS.Message.IHE.XDSb.Metadata) as %Status
    Take the inbound request, update the metadata with any missing values

    BuildDistributionSet takes the inbound HS.Message.IHE.XDM.DistributeDocumentSetRequest and
  • Calls ValidateRequest
  • For each submission calls UpdateRequest
  • calls IndexAndHeaders
  • calls ZipOperation host if defined
  • calls PostCreationOperation host (if defined) with a new HS.Message.IHE.XDM.DistributeDocumentSetRequest

  • Optionally define customization class by setting CustomProcessor to class name and define either method

    Tracing in the methods with HSTRACECALLED, HSTRACECALLEDMIN, HSTRACECALLEDERROR
    Call out to other business hosts using pHost.SendRequestAsync or pHost.SendRequest.Sync

    ClassMethod OnPreUpdateRequest(pHost As Ens.Host , Output pStopProcessing as %Boolean, pRequest As HS.Message.IHE.XDM.DistributeDocumentSetRequest) as %Status()
  • if pStopProcessing is true processing will terminate with tSC (either ok or error).
  • Updates can be done to the DistributeDocumentSet object prior to any additional processing, such as providing necessary missing fields
  • ClassMethod OnPostUpdateRequest(pHost As Ens.Host, pRequest as HS.Message.IHE.XDM.DistributeDocumentSetRequest) as %Status()
  • Additional processing can be done to the response, or the response itself can be updated
  • ValidateRequest takes the inbound HS.Message.IHE.XDM.DistributeDocumentSetRequest and can optionally update the newly created response (HS.Message.IHE.XDM.DistributeDocumentSetResponse)
  • Validates there are Submissions in the request
  • Validates each submission (HS.Message.IHE.XDSb.Metadata) has a submission set

  • Optionally define customization class by setting CustomProcessor to class name and define either method

    Tracing in the methods with HSTRACECALLED, HSTRACECALLEDMIN, HSTRACECALLEDERROR
    Call out to other business hosts using pHost.SendRequestAsync or pHost.SendRequest.Sync

    ClassMethod OnPreValidateRequest(pHost As Ens.Host , Output pStopProcessing as %Boolean, pRequest As HS.Message.IHE.XDM.DistributeDocumentSetRequest, Output pResponse as HS.Message.IHE.XDM.DistributeDocumentSetResponse) as %Status()
  • if pStopProcessing is true processing will terminate with tSC (either ok or error).
  • ClassMethod OnPostBuildDistributionSet(pHost As Ens.Host, pRequest As HS.Message.IHE.XDM.DistributeDocumentSetRequest, Output pResponse as HS.Message.IHE.XDM.DistributeDocumentSetResponse) as %Status()
  • Additional processing can be done to the response, or the response itself can be updated
  • Inherited Members

    Inherited Properties

    Inherited Methods

    Storage

    Gray indicates storage defined by superclasses.

    Storage Model: Storage (Ens.BusinessProcess)

    ^Ens.BusinessProcessD(ID,"received",n)
    =
    %MessagesReceived(n)

    Storage Model: Storage (Ens.BusinessProcess)

    ^Ens.BusinessProcessD(ID,"sent",n)
    =
    %MessagesSent(n)

    Storage Model: Storage (Ens.BusinessProcess)

    ^Ens.BusinessProcessD(ID)
    =
    %%CLASSNAME
    %ConfigQueueName
    %IsCompleted
    %MasterPendingResponsesOld
    %PrimaryRequestHeader
    %PrimaryResponseHeader
    %RepliedStatus
    %responseId
    Adapter
    %SessionId
    %TimeCompleted
    %TimeCreated
    %ConfigName
    %QuitTask
    AlertOnError
    %responseClassName
    %IsTimerInterrupted
    %IsTerminated
    %StatusCode
    %MessagesReceivedOld
    %MessagesSentOld
    ReplyCodeActions
    RetryInterval
    AlertRetryGracePeriod
    FailureTimeout
    Retry
    SuspendMessage
    QueueCountAlert
    QueueWaitAlert
    InactivityTimeout
    BusinessPartner
    AlertGroups
    %SuperSession

    Storage Model: Storage (HS.IHE.XDM.PortableMediaCreator.Process)

    ^Ens.BusinessProcessD(ID,"Process")
    =
    DocumentsInline
    TraceOperations
    DocumentTransform
    XSLTErrorHandlerClass
    PostCreationOperation
    CallbackHandler
    ErrorHandler
    HTMLFooter
    AssumeMinimal
    DoHSTrace
    ClearCallbackVariables
    HTMLHeader
    Initialized
    ReadMe
    XSLTCacheMode
    XSLTCallbackHandlerClass
    XSLTDirectory
    ZipOperation
    PostCreationOperation
    CustomProcessor
    CustomProcessorIsValid
    Errors
    DefaultAuthorTelecommunication
    PIXv3ConsumerOperations
    MetadataTransform
    AddNewPatients
    MPIOperations
    UseXSLT2

    Storage Model: Storage (HS.IHE.XDM.PortableMediaCreator.Process)

    ^Ens.BusinessProcessD(ID,"HS.IHE.XDM.PortableMediaCreator.Process.StyleSheets",n)
    =
    StyleSheets(n)
    FeedbackOpens in a new tab