HL7 Module 10.5 | Understanding and Using HL7 Module | Installing and Using HL7 Module | webMethods HL7 Module Services | WmHL7 Package | wm.ip.hl7.tn.service:receive
 
wm.ip.hl7.tn.service:receive
Receives HL7 version 2.x messages sent by a trading partner using the specified Trading Networks transport protocol.
Usage Notes
The receive service reads the input stream and converts it into an internal Java object that it stores in the Trading Networks database. When reading the input stream content, the service determines which charset encoding to use as described in the following steps:
1. Searches for the Content-Type property in the header of the message. The value of Content-Type can contain the charset information. If the charset information is provided in Content-Type, the service reads the input stream message with this charset and ignores the charset encoding provided in the TPA. For example, when the value of Content-Type in the header is Content-Type=text/plain; charset=utf-8, the service will use utf-8 as the charset encoding.
2. If no Content-Type property is found in the header of the message, the service reads the input stream with the system default charset encoding and then constructs the HL7 message object.
3. Obtains the Sender and Receiver ID from the HL7 message and retrieves the TPA for this Sender and Receiver ID.
4. Obtains the charset encoding from the retrieved TPA. If it is not present in the retrieved TPA, the service uses the charset encoding from the default TPA.
5. If the charset encoding specified in the TPA is different from the system default encoding, the service reads the input stream again with the encoding specified in the TPA.
Input Parameters
ffdata
Object Optional. The incoming HL7 message in the form of a stream.
Note:
This parameter is filled in internally with the HL7 message when it is received via HTTP.
contentStream
ObjectOptional. The incoming HL7 message in the form of a stream.
Note:
This parameter is filled in internally with the HL7 message when it is received via FTP.
Output Parameters
response
byte [ ] When you use the synchronous delivery mode, the value of the response parameter is the payload of the acknowledgement message. The value of the response parameter is sent as a response to the Sender.