@Override protected void update(String username) { storageApi.update(elementDescription); } }
@Override protected void update(String username) { storageApi.update(elementDescription); } }
@Override protected void update(String username) { storageApi.update(elementDescription); }
@Override protected void update(String username) { storageApi.update(elementDescription); }
@Override protected void update(String username) { storageApi.update(elementDescription); }
@Override protected void update(String username) { storageApi.update(elementDescription); }
@Override public boolean update(DataSourceDescription sep) { boolean success = sesameStorage.update(sep); initializeSEPStorage(); return success; }
@Override public boolean update(DataSinkDescription sec) { boolean success = sesameStorage.update(sec); initializeSECStorage(); return success; }
@Override public boolean update(DataProcessorDescription sepa) { boolean success = sesameStorage.update(sepa); initializeSEPAStorage(); return success; }
@Override public boolean update(DataProcessorDescription sepa) { boolean success = sesameStorage.update(sepa); initializeSEPAStorage(); return success; }
@Override public boolean update(DataSourceDescription sep) { boolean success = sesameStorage.update(sep); initializeSEPStorage(); return success; }
@Override public boolean update(DataSinkDescription sec) { boolean success = sesameStorage.update(sec); initializeSECStorage(); return success; }
@POST @Path("/update") @Produces(MediaType.APPLICATION_JSON) @Consumes(MediaType.MULTIPART_FORM_DATA) public Response directUpdate(@PathParam("username") String username, @FormDataParam("config") String config, @FormDataParam("model") String model) { DeploymentConfiguration deploymentConfig = fromJson(config); boolean success; if (deploymentConfig.getElementType().equals("Sepa")) { DataProcessorDescription sepa = GsonSerializer.getGsonWithIds().fromJson(model, DataProcessorDescription.class); success = StorageManager.INSTANCE.getStorageAPI().deleteSEPA(sepa.getElementId()); StorageManager.INSTANCE.getStorageAPI().storeSEPA(sepa); } else { DataSinkDescription sec = new DataSinkDescription(GsonSerializer.getGsonWithIds().fromJson(model, DataSinkDescription.class)); success = StorageManager.INSTANCE.getStorageAPI().update(sec); } if (success) return ok(Notifications.success("Element description updated.")); else return ok(Notifications.error("Could not update element description.")); }