ValidateHL7 CallBack

Overview

By using the ValidateHL7 CallBack, you can select the validation guidelines and profiles based on the contents of the input data by modifying the Java code.

Enable Callback

To enable the ValidateHL7 CallBack:

  1. Select the TIBCO ActiveMatrix BusinessWorks Application Module when creating a new project.

  2. Enter a Project name, select the Use Java configuration check box, and click Next.

  3. Select the CallBack check box on the General tab of the ValidateHL7 activity and click Create a new class .

  4. Fill in Class Name and click Finish.

    A Java class is created with default functions and variables.

Result

The following MSH information is set to HashMap<String, String> infoMap.
 key = Info.ReceivingApplicationUniversalID 
 key = Info.SendingFacilityNamespaceID
 key = Info.MessageTypeMessageStructure
 key = Info.MessageHeader, value = MSH
 key = Info.SendingFacilityUniversalID 
 key = Info.ReceivingFacilityUniversalID
 key = Info.id, value = HL7
 key = Info.SendingFacilityUniversalIDType 
 key = Info.ReceivingFacilityUniversalIDType 
 key = Info.SendingApplicationNamespaceID
 key = Info.DateTimeofMessage
 key = Info.ReceivingApplicationNamespaceID 
 key = Info.ReceivingApplicationUniversalIDType 
 key = Info.SendingApplicationUniversalID 
 key = Info.Version
 key = Info.ReceivingFacilityNamespaceID
 key = Info.MessageTypeTriggerEvent
 key = Info.SendingApplicationUniversalIDType 
 key = Info.MessageTypeMessageCode

Use the “get” function to access the values in the map.

infoMap.get("Info.MessageTypeMessageCode")

Setting Guidelines and Profiles

You can set guidelines and profiles by modifying public void selectGuideline() in the Java code.

Refer to the associated examples:

If Guideline Resides on Disk (Instream Database Directory)

Sign the map image to the variable mapFileBuffer.

guidelineName = “VXR_V03.std”;

If Guideline Resides in Memory (Database)

  1. Sign the guideline image to variable guidelineByteBuffer.

    guidelineByteBuffer=(guideline in byte[]);

  2. Sign the guideline name to variable guidelineName.

    guidelineName = “VXR_V03.std”;

Setting a Profile

Directly assign the profile name to the variable apfFileName.

apfFilename=”user_profile.apf”;