![]() |
hapi - is it possible to get information from abstract structures like Message?
Hi!
Does anybody know how to get information from hapi basic structures (when for example receiving a message from an unsupported version protocol). Say you start with an instance of ca.uhn.hl7v2.model.Message and you want to work with the values of the MSH segment. How is that done? Thanks in advance. |
ExampleUseTerser looks relevant. Also see HandlingMultipleVersions
|
I find it quite interesting.... however I don't know the different protocol versions that much to know if they change a lot between them (hell, I don't know any of them too well). What I will end up doing is supporting all protocol versions I need and use instanceof and casting a lot.
Code:
if (message instanceof ca.uhn.hl7v2.model.v21.message.ORU_R01) { |
By the way, I took that from a previous revision of my code so I think the way I'm getting the patient ID is not correct... but you get the concept, don't you?
|
| All times are GMT -5. The time now is 06:21 AM. |