Mercurial > hg > AnnotationManagerN4J
diff src/main/java/de/mpiwg/itgroup/annotations/restlet/AnnotatorResourceImpl.java @ 40:03e0f7574224
saving and loading resource targets should work now (no searching yet)
author | casties |
---|---|
date | Wed, 26 Sep 2012 14:56:42 +0200 |
parents | b1fb0d117877 |
children | 0e00bf8e27fb |
line wrap: on
line diff
--- a/src/main/java/de/mpiwg/itgroup/annotations/restlet/AnnotatorResourceImpl.java Wed Sep 26 11:47:38 2012 +0200 +++ b/src/main/java/de/mpiwg/itgroup/annotations/restlet/AnnotatorResourceImpl.java Wed Sep 26 14:56:42 2012 +0200 @@ -187,6 +187,9 @@ try { jo.put("text", annot.getBodyText()); jo.put("uri", annot.getTargetBaseUri()); + if (annot.getResourceUri() != null) { + jo.put("resource", annot.getResourceUri()); + } /* * user @@ -441,6 +444,12 @@ annot.setTargetBaseUri(jo.getString("uri")); } /* + * resource uri + */ + if (jo.has("resource")) { + annot.setResourceUri(jo.getString("resource")); + } + /* * annotation text */ if (jo.has("text")) {