Re: [HAPI-devel] Please ignore, The message processed was messed up

2015-11-16 Thread Davies, Brian
From: Davies, Brian [mailto:brian.dav...@mckesson.com] Sent: Monday, November 16, 2015 2:00 PM To: hl7api-devel@lists.sourceforge.net Subject: [HAPI-devel] Is there a way to use fields which do not follow a linear sequence? I have a structure which follows the order in a segment MSH ZDD

[HAPI-devel] Is there a way to use fields which do not follow a linear sequence?

2015-11-16 Thread Davies, Brian
I have a structure which follows the order in a segment MSH ZDD Field Sequence Marital Status1 Age 3 DOB 4

Re: [HAPI-devel] ClassCastException when casting down

2015-11-16 Thread Davies, Brian
Thanks a lot Christian, really appreciated. From: Christian Ohr [mailto:christian@gmail.com] Sent: Monday, November 16, 2015 8:23 AM To: Davies, Brian Cc: hl7api-devel@lists.sourceforge.net Subject: Re: [HAPI-devel] ClassCastException when casting down In your case, nothing tells HAPI to inst

Re: [HAPI-devel] Does the HAPI Library honor groups when extending MFN_M01?

2015-11-16 Thread Christian Ohr
I think my previous answer also applies to this question. Of course you can also define groups for custom structure classes. Christian 2015-10-27 15:27 GMT+01:00 Davies, Brian : > I am extending the MFN_M01 message as this is provided by a 3rd party to > an app that I am working on. I extended

Re: [HAPI-devel] ClassCastException when casting down

2015-11-16 Thread Christian Ohr
In your case, nothing tells HAPI to instantiate a "PFM" message when it comes across a message with MFN^M01 in the MSH-9 field. This is the task of the so-called event map. It's a file located in the ca.uhn.hl7v2.parser.eventmap package and called .properties (i.e. in your case "2.5.properties").

Re: [HAPI-devel] ClassCastException

2015-11-16 Thread Christian Ohr
That's because in Java you cannot cast a Type[] into a ST[] (although you can cast a Type into a ST). There are some convenience methods in the superclass: return getTypedField(1, new ST[0]); // Alternatively use Arrays.copyOf // instead of return (ST[]) super.getField(1); return getTypedField