comparison src/main/java/de/mpiwg/itgroup/annotationManager/restlet/SearchAnnotations.java @ 33:e5f5848892a2

new annotation model basically works.
author casties
date Thu, 31 May 2012 19:08:48 +0200
parents 235b91ba8dff
children
comparison
equal deleted inserted replaced
32:40846c0b344d 33:e5f5848892a2
87 e1.printStackTrace(); 87 e1.printStackTrace();
88 setStatus(Status.CLIENT_ERROR_NOT_ACCEPTABLE); 88 setStatus(Status.CLIENT_ERROR_NOT_ACCEPTABLE);
89 return null; 89 return null;
90 } 90 }
91 91
92 RDFSearcher searcher = new RDFSearcher("file:///annotations"); //TODO should ge into config file 92 RDFSearcher searcher = new RDFSearcher(NS.MPIWG_ANNOT_CTX); //TODO should ge into config file
93 93
94 String retString="<html><body><table>"; 94 String retString="<html><body><table>";
95 String lineFormat="<tr><td><a href=\"%s\">%s</a></td>" + 95 String lineFormat="<tr><td><a href=\"%s\">%s</a></td>" +
96 "<td><a href=\"%s\">%s</a></td><td>%s</td><td>%s</td><td><a href=\"%s\">%s</a></td><td><a href=\"%s\">%s</a></td></div>"; 96 "<td><a href=\"%s\">%s</a></td><td>%s</td><td>%s</td><td><a href=\"%s\">%s</a></td><td><a href=\"%s\">%s</a></td></div>";
97 try { 97 try {
188 String limit=form.getFirstValue("limit"); 188 String limit=form.getFirstValue("limit");
189 String offset=form.getFirstValue("offset"); 189 String offset=form.getFirstValue("offset");
190 190
191 191
192 // 192 //
193 RDFSearcher searcher = new RDFSearcher("file:///annotations"); //TODO should ge into config file 193 RDFSearcher searcher = new RDFSearcher(NS.MPIWG_ANNOT_CTX); //TODO should ge into config file
194 194
195 JSONArray ja; 195 JSONArray ja;
196 try { 196 try {
197 197
198 List<Annotation> annots=searcher.searchByUriUser(uri,user,limit,offset); 198 List<Annotation> annots=searcher.searchByUriUser(uri,user,limit,offset);