Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

...

Archie can serialize RM Objects to XML using the standard openEHR RM XSD, or it can be used to serialize to JSON. The format we have now is very similar that the one Marand uses: snake_cased attribute names, type names as the same notation as the RM specs. Our EHR is still in the prototype phase, so the format is still subject to change, and no results from AQL queries yet.

The code to configure Jackson (XML serialization library) to serialize to /from this exact format is not yet or parse it to RM Objects is present in Archie starting from version 0.2.1

Code Block
languagejs
 "data" : {
      "type@type" : "HISTORY",
      "name" : {
        "type@type" : "DV_TEXT",
        "value" : "history"
      },
      "archetype_node_id" : "id2",
      "events" : [ {
        "type@type" : "POINT_EVENT",
        "name" : {
          "type@type" : "DV_TEXT",
          "value" : "any event"
        },
        "archetype_node_id" : "id7",
        "time" : {
          "type@type" : "DV_DATE_TIME",
          "magnitude" : 1466427403,
          "value" : "2016-06-20T14:56:43.702+02:00"
        },    
		"data" : {
          "type@type" : "ITEM_TREE",
          "name" : {
            "type" : "DV_TEXT"
          },
          "archetype_node_id" : "id4",
          "items" : [ {
            "type@type" : "ELEMENT",
            "name" : {
              "type@type" : "DV_TEXT",
              "value" : "Systolic"
            },
            "archetype_node_id" : "id5",
            "value" : {
              "type@type" : "DV_QUANTITY",
              "magnitude" : 120.0,
              "precision" : 0,
              "units" : "mm[Hg]"
            },
            "path" : "/data[id2]/event[id7]/data[id4]/item[id5]"
          }, {
            "type@type" : "ELEMENT",
            "name" : {
              "type@type" : "DV_TEXT",
              "value" : "Diastolic"
            },
            "archetype_node_id" : "id6",
            "value" : {
              "type@type" : "DV_QUANTITY",
              "magnitude" : 80.0,
              "precision" : 0,
              "units" : "mm[Hg]"
            },
            "path" : "/data[id2]/event[id7]/data[id4]/item[id6]"
          },







...