@Override protected Action deprecatedPopulate(Action model, List entity) { model.setId(asString(ids)); if (model.isSetFault()) { setReason(model.getFault()); } return model; }
protected Response actionAsync(ActionReturnValue actionResult, Action action) { action.setAsync(true); String ids = asString(actionResult.getVdsmTaskIdList()); action.setId(ids); Current current = CurrentManager.get(); String path = current.getRelativePath(); action.setHref(path + "/" + ids); addOrUpdateLink(action, "parent", path.substring(0, path.lastIndexOf("/"))); addOrUpdateLink(action, "replay", path); CreationStatus status = getAsynchronousStatus(actionResult); if (status != null) { action.setStatus(status.value()); } return Response.status(ACCEPTED_STATUS).entity(action).build(); }
Action to = new Action(); if (from.isSetId()) { to.setId(from.getId());