Hi Derek,
The character encodings are only ever applied when the message is
transmitted over a network socket using a LowerLayerProtocol impementation
(either MLLP or HL7-over-HTTP). At all other times, HAPI uses Java Strings
to represent any textual data, which means that everything is in UTF-16.
In other words, setting the system property you mentioned will mean that if
you create a new client with no other configuration, once your application
connects to a remote server it will encode your message in the given
charset before sending it.
FWIW, there is a page in the HAPI examples section that shows some
alternate ways of specifying the charset. Personally I hate using system
properties..
http://hl7api.sourceforge.net/xref/ca/uhn/hl7v2/examples/HandlingCharacterEncodings.html
Cheers,
James
On Tue, Apr 30, 2013 at 12:50 PM, Derek Mahar <derek.ma...@intelerad.com>wrote:
> In a HAPI client application, what HAPI class methods apply the character
> encoding that system property "ca.uhn.hl7v2.llp.charset" determines?
> Does HAPI apply the encoding when it populates messages? Does method
> "Initiator.sendAndReceive(Message)" apply the encoding? Does a PipeParser
> method apply the encoding?
>
> I'm trying to pin-point in a HAPI client application which HAPI method
> call is translating UTF-8 character "0xc3 0xa9" ('é') to "0xe9 0x5c" on
> output.
>
> Thank you,
>
> Derek
>
> --
> Derek Mahar | Research and Development - Intelerad
> +1-514-931-6222 ext. 7754 |
> derek.ma...@intelerad.com<peter.nee...@intelerad.com>
>
> Website | Twitter | LinkedIn | Blog
>
>
> This email or any attachments may contain confidential or legally
> privileged information intended for the sole use of the addressees. Any
> use, redistribution, disclosure, or reproduction of this information,
> except as intended, is prohibited. If you received this email in error,
> please notify the sender and remove all copies of the message, including
> any attachments.
>
>
>
> ------------------------------------------------------------------------------
> Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET
> Get 100% visibility into your production application - at no cost.
> Code-level diagnostics for performance bottlenecks with <2% overhead
> Download for free and get started troubleshooting in minutes.
> http://p.sf.net/sfu/appdyn_d2d_ap1
> _______________________________________________
> Hl7api-devel mailing list
> Hl7api-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/hl7api-devel
>
>
------------------------------------------------------------------------------
Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET
Get 100% visibility into your production application - at no cost.
Code-level diagnostics for performance bottlenecks with <2% overhead
Download for free and get started troubleshooting in minutes.
http://p.sf.net/sfu/appdyn_d2d_ap1
_______________________________________________
Hl7api-devel mailing list
Hl7api-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/hl7api-devel