From 6575c8095bd026d0507a8f15393be1a348e6be41 Mon Sep 17 00:00:00 2001 From: Tanja de Jong Date: Mon, 10 Sep 2018 15:23:44 +0200 Subject: [PATCH] Add @XmlRootElement annotations to some data structures --- .../java/com/nedap/archie/rm/datastructures/Element.java | 6 ++---- .../java/com/nedap/archie/rm/datastructures/ItemList.java | 2 ++ .../java/com/nedap/archie/rm/datastructures/ItemTable.java | 2 ++ 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/Element.java b/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/Element.java index 168e673c8..bdb24eb5c 100644 --- a/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/Element.java +++ b/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/Element.java @@ -5,10 +5,7 @@ import com.nedap.archie.rm.datavalues.SingleValuedDataValue; import javax.annotation.Nullable; -import javax.xml.bind.annotation.XmlAccessType; -import javax.xml.bind.annotation.XmlAccessorType; -import javax.xml.bind.annotation.XmlElement; -import javax.xml.bind.annotation.XmlType; +import javax.xml.bind.annotation.*; /** * Created by pieter.bos on 04/11/15. @@ -18,6 +15,7 @@ "value", "nullFlavour" }) +@XmlRootElement(name="element") public class Element extends Item implements SingleValuedDataValue { @Nullable diff --git a/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/ItemList.java b/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/ItemList.java index 488417348..2dad6baca 100644 --- a/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/ItemList.java +++ b/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/ItemList.java @@ -3,6 +3,7 @@ import javax.annotation.Nullable; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlRootElement; import javax.xml.bind.annotation.XmlType; import java.util.ArrayList; import java.util.List; @@ -14,6 +15,7 @@ @XmlType(name = "ITEM_LIST", propOrder = { "items" }) +@XmlRootElement(name="item_list") public class ItemList extends ItemStructure { @Nullable diff --git a/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/ItemTable.java b/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/ItemTable.java index 8915d6059..bfe1fea72 100644 --- a/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/ItemTable.java +++ b/openehr-rm/src/main/java/com/nedap/archie/rm/datastructures/ItemTable.java @@ -3,6 +3,7 @@ import javax.annotation.Nullable; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlRootElement; import javax.xml.bind.annotation.XmlType; import java.util.ArrayList; import java.util.List; @@ -14,6 +15,7 @@ @XmlType(name = "ITEM_TABLE", propOrder = { "rows" }) +@XmlRootElement(name="item_table") public class ItemTable extends ItemStructure { @Nullable