|
From: João A. B. L. P. <jp...@ut...> - 2012-05-12 19:26:40
|
Hi everyone.
Could you please help me out on this?
I needed a new message, called NMD. So I created one based on the HAPI, using HAPI's segments .
The NMD has the following segments:
MSH
NCK (System time)
[NTE] (Note/comment)
After that I created one message, based on the "CreateAMessage" example, but this time using the just created NMD.class, I filled MSH, but I do not know how to set NCK. It appears to have only a get() and not a set() - And that makes some sense. However when I print the message, in the ER7 form it simply doesn't appear. In the XML it appears an empty single tag (<NCK/>). Shouldn't be something like <NCK yyyyMMddHHmmss)/> ?
Printing ER7 Encoded Message:
MSH|^~\&|jpavao-NMD-CreatedNewMessageType||||201205121945||NMD||||123
Printing XML Encoded Message:
<?xml version="1.0"?>
<NMD xmlns="urn:hl7-org:v2xml">
<MSH>
<MSH.1>|</MSH.1>
<MSH.2>^~\&</MSH.2>
<MSH.3>
<HD.1>jpavao-NMD-CreatedNewMessageType</HD.1>
</MSH.3>
<MSH.7>
<TS.1>201205121945</TS.1>
</MSH.7>
<MSH.9>
<CM_MSG.1>NMD</CM_MSG.1>
</MSH.9>
<MSH.13>123</MSH.13>
</MSH>
<NCK/>
</NMD>
|