Hi, Have you tried ca.uhn.hl7v2.util.Terser? The set() and get() methods access fields in a version-independent way (as much as possible) and there is also getSegment() if you want a whole segment.
Bryan On 6/19/07, granger44 <[EMAIL PROTECTED]> wrote: > > > fer wrote: > > > > Hello, I newbie in HAPI. > > > > Any example how to read the segment fields and then its components. > > I want a solution all version compatible. > > > > > > I too am looking for something to extract segments from a message regardless > of version. The closest I've come so far is to encode the message into XML > and then do some XML/XPath parsing. The big downside is that it's two > transforms so it's not very scalable; if someone has a quicker solution, I'd > be very interested. > > -- > View this message in context: > http://www.nabble.com/Read-Generic-Message-tf2925245.html#a11123924 > Sent from the hl7api-devel mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > Hl7api-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/hl7api-devel > ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Hl7api-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/hl7api-devel

