public class HL7DataFormat
extends org.apache.camel.support.ServiceSupport
implements org.apache.camel.spi.DataFormat, org.apache.camel.spi.DataFormatName
HL7MLLPCodec| Constructor and Description |
|---|
HL7DataFormat() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
doStart() |
protected void |
doStop() |
String |
getDataFormatName() |
ca.uhn.hl7v2.HapiContext |
getHapiContext() |
ca.uhn.hl7v2.parser.Parser |
getParser() |
protected String |
guessCharsetName(byte[] b,
org.apache.camel.Exchange exchange)
In HL7 the charset of the message can be set in MSH-18,
but you need to decode the input stream in order to be able to read MSH-18.
|
boolean |
isValidate() |
void |
marshal(org.apache.camel.Exchange exchange,
Object body,
OutputStream outputStream) |
void |
setHapiContext(ca.uhn.hl7v2.HapiContext context) |
void |
setParser(ca.uhn.hl7v2.parser.Parser parser) |
void |
setValidate(boolean validate) |
Object |
unmarshal(org.apache.camel.Exchange exchange,
InputStream inputStream) |
public String getDataFormatName()
getDataFormatName in interface org.apache.camel.spi.DataFormatNamepublic void marshal(org.apache.camel.Exchange exchange,
Object body,
OutputStream outputStream)
throws Exception
marshal in interface org.apache.camel.spi.DataFormatExceptionpublic Object unmarshal(org.apache.camel.Exchange exchange, InputStream inputStream) throws Exception
unmarshal in interface org.apache.camel.spi.DataFormatExceptionpublic boolean isValidate()
public void setValidate(boolean validate)
public ca.uhn.hl7v2.HapiContext getHapiContext()
public void setHapiContext(ca.uhn.hl7v2.HapiContext context)
public ca.uhn.hl7v2.parser.Parser getParser()
public void setParser(ca.uhn.hl7v2.parser.Parser parser)
protected void doStart()
throws Exception
doStart in class org.apache.camel.support.ServiceSupportExceptionprotected void doStop()
throws Exception
doStop in class org.apache.camel.support.ServiceSupportExceptionprotected String guessCharsetName(byte[] b, org.apache.camel.Exchange exchange)
IOHelper.getCharsetName(org.apache.camel.Exchange).b - byte arrayexchange - the exchangeApache Camel