ca.uhn.hl7v2.protocol.impl
Class AppWrapper
java.lang.Object
ca.uhn.hl7v2.protocol.impl.AppWrapper
- All Implemented Interfaces:
- ReceivingApplication
public class AppWrapper
- extends Object
- implements ReceivingApplication
Wraps a ca.uhn.hl7v2.app.Application as a ca.uhn.hl7v2.protocol.ReceivingApplication.
ReceivingApplication replaces Application with HAPI 0.5.
- Version:
- $Revision: 1.1 $ updated on $Date: 2007-02-19 02:24:26 $ by $Author: jamesagnew $
- Author:
- Bryan Tripp
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AppWrapper
public AppWrapper(Application theApplication)
- Parameters:
theApplication - an Application to wrap as a ReceivingApplication.
processMessage
public Message processMessage(Message theMessage,
Map<String,Object> theMetadata)
throws ReceivingApplicationException,
HL7Exception
- Description copied from interface:
ReceivingApplication
- Uses the contents of the message for whatever purpose the application
has for this message, and returns an appropriate response message.
- Specified by:
processMessage in interface ReceivingApplication
- Parameters:
theMessage - an inbound HL7 messagetheMetadata - message metadata (which may include information about where the message comes
from, etc). This is the same metadata as in Transportable.
- Returns:
- an appropriate application response (for example an application ACK or query response).
Appropriate responses to different types of incoming messages are defined by HL7.
- Throws:
ReceivingApplicationException - if there is a problem internal to the application (for example
a database problem)
HL7Exception - if there is a problem with the message- See Also:
ReceivingApplication.processMessage(ca.uhn.hl7v2.model.Message, java.util.Map)
canProcess
public boolean canProcess(Message theMessage)
- Specified by:
canProcess in interface ReceivingApplication
- Parameters:
theMessage - an inbound HL7 message
- Returns:
- true if this ReceivingApplication wishes to accept the message. By returning
true, this Application declares itself the recipient of the message, accepts
responsibility for it, and must be able to respond appropriately to the sending system.
- See Also:
ReceivingApplication.canProcess(ca.uhn.hl7v2.model.Message)
Copyright © 2001-2012 University Health Network. All Rights Reserved.