예제 #1
0
 @Test
 public void list_backups_1() {
   try (TypedInputStream in = execHttpGet(urlRoot + "$/" + opListBackups)) {
     assertEqualsIgnoreCase(WebContent.contentTypeJSON, in.getContentType());
     JsonValue v = JSON.parseAny(in);
     assertNotNull(v.getAsObject().get("backups"));
   }
 }
예제 #2
0
 @Test
 public void list_datasets_2() {
   try (TypedInputStream in = execHttpGet(urlRoot + "$/" + opDatasets)) {
     assertEqualsIgnoreCase(WebContent.contentTypeJSON, in.getContentType());
     JsonValue v = JSON.parseAny(in);
     assertNotNull(v.getAsObject().get("datasets"));
     checkJsonDatasetsAll(v);
   }
 }
예제 #3
0
 @Override
 public void handle(String baseIRI, HttpResponse response) throws IOException {
   try (InputStream in = response.getEntity().getContent()) {
     result = JSON.parseAny(in);
   }
 }