Serialization of GTS type
psharp
#1 Posted : Thursday, March 6, 2014 6:45:02 PM(UTC)
Rank: Member

Groups: Registered
Joined: 11/12/2013(UTC)
Posts: 19
Points: 57

Thanks: 3 times
Was thanked: 0 time(s) in 0 post(s)
Hi Everest,

I'm having an issue where the GTS type (SubstanceAdministration.EffectiveTime) isn't showing the xsi:type when I think it is required.

If I create the GTS type using:
Code:
List<GTS> effectiveTime = new List<GTS>() { new IVL<TS>(startTime, endTime) };


Quote:
<effectiveTime>
<low value="20130828" />
<high value="20131002" />
</effectiveTime>


If I create the GTS using a different type like PIVL<TS>
Code:
List<GTS> effectiveTime = new List<GTS>() { new PIVL<TS>(new IVL<TS>() {Low = startTime}, new PQ(5m, "units")) };


Quote:
<effectiveTime>
<phase>
<low value="20130828" />
</phase>
<period unit="units" value="5" />
</effectiveTime>


I believe the first one should be:
Quote:
<effectiveTime xsi:type="IVL_TS">
<low value="20130828" />
<high value="20131002" />
</effectiveTime>

with maybe an Operator attribute also, not sure.

The second would be xsi:type="PIVL_TS"

Can you advise?
justin.fyfe1
#2 Posted : Thursday, March 6, 2014 7:16:02 PM(UTC)

Rank: Administration

Medals: Mobile Tech Grasshopper: Mobile Tech GrasshopperHealth Informatics MVP

Groups: Registered, Administrators
Joined: 7/22/2010(UTC)
Posts: 96
Points: 297
Man
Location: Hamilton, ON

Thanks: 2 times
Was thanked: 17 time(s) in 17 post(s)
You are correct, this is a bug. I will look into it tomorrow morning.
justin.fyfe1
#3 Posted : Friday, March 7, 2014 8:23:53 AM(UTC)

Rank: Administration

Medals: Mobile Tech Grasshopper: Mobile Tech GrasshopperHealth Informatics MVP

Groups: Registered, Administrators
Joined: 7/22/2010(UTC)
Posts: 96
Points: 297
Man
Location: Hamilton, ON

Thanks: 2 times
Was thanked: 17 time(s) in 17 post(s)
Hmm... That is interesting...

I found the bug :

Code:

// Not for CDA:
            if (result.CompatibilityMode == DatatypeFormatterCompatibilityMode.ClinicalDocumentArchitecture && (instanceHull is SXCM<TS>))
                ;
            else
            {
                string xsiTypeName = Util.CreateXSITypeName(instanceHull.GetType());
                s.WriteAttributeString("xsi", "type", DatatypeFormatter.NS_XSI, xsiTypeName);
            }


I'll have to dig through my notes and see why this behavior was put into Everest.. I'll let you know as soon as I have a fix.

Cheers
-Justin
psharp
#4 Posted : Tuesday, March 11, 2014 5:16:34 PM(UTC)
Rank: Member

Groups: Registered
Joined: 11/12/2013(UTC)
Posts: 19
Points: 57

Thanks: 3 times
Was thanked: 0 time(s) in 0 post(s)
Any luck?
justin.fyfe1
#5 Posted : Tuesday, March 11, 2014 5:19:49 PM(UTC)

Rank: Administration

Medals: Mobile Tech Grasshopper: Mobile Tech GrasshopperHealth Informatics MVP

Groups: Registered, Administrators
Joined: 7/22/2010(UTC)
Posts: 96
Points: 297
Man
Location: Hamilton, ON

Thanks: 2 times
Was thanked: 17 time(s) in 17 post(s)
Yeah, it is fixed in SVN. I'll bundle it up and release on the website.

EDIT: It appears as though the change is in 1.2.14
Users browsing this topic
Guest (3)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

SoClean Theme By Jaben Cargman (Tiny Gecko)
Powered by YAF 1.9.4 | YAF © 2003-2010, Yet Another Forum.NET
This page was generated in 0.108 seconds.