From: Tripp, B. <Bry...@uh...> - 2004-05-26 15:30:56
|
Hi Martin, Yes, you're right, the example org.foo.hl7.custom.messages.ZFO should read org.foo.hl7.custom.message.ZFO. Thanks for pointing this out. I don't want to have a troubleshooting dialogue on the list, but could you please mail me personally and let me know what log messages you get if you call packageList() with log level debug? Thanks, Bryan > -----Original Message----- > From: Martin Fleurke [mailto:mar...@po...] > Sent: May 26, 2004 11:13 AM > To: Tripp, Bryan > Cc: Hl7...@li... > Subject: creating own messages [was: Re: [HAPI-devel] Further TXA > questions] > > > Tripp, Bryan wrote: > > >5. The above steps are enough to allow you create and encode > messages in the > >custom format. If you also want to parse them, follow the > instructions in > >the JavaDocs for Parser.packageList() to register your > message class with > >the parsers. > >Let me know if any of the above is unclear. > > > > > Hi, > > I am also using my own messages, but registering the class > doesn't seem > to work. What am I doing wrong? > > I have messages like > nl.portavita.hl7messages.model.v1.message.PVL_PV1 > (extends abstractmessage) and message segments like > nl.portavita.hl7messages.model.v1.segment.LGA > (extends AbstractSegment). > > In my userdir I have created the directory 'custom_packages' with the > file '2.2'. > The contents of the file are: 'nl.portavita.hl7messages.model.v1' > > calling Parser.packageList results only in {'ca.uhn.hl7v2.model.v22.'} > > if I do (in processmessage(Message in)) > LGA lga = (LGA)in.get("LGA"); > I get a classcastexception. (the 'get-method' returns an > abstractSegement, and if I inspect it, i can find the > complete original > message somewhere inside) > > I have decided to put the messages under '.message', as > happens in the > HAPI, but the JavaDoc has an example with '.messages'. Do I need to > place all messages under '.messages' instead? Or do I have to > place the > file somewehere else, or do I need to load the file somehow? > > Regards, > Martin > This e-mail may contain confidential and/or privileged information for the sole use of the intended recipient. Any review or distribution by anyone other than the person for whom it was originally intended is strictly prohibited. If you have received this e-mail in error, please contact the sender and delete all copies. Opinions, conclusions or other information contained in this e-mail may not be that of the organization. |