+ projectSlug + "/" + iterationSlug + "/" + docId);
}
identity.checkPermission("copy-trans", document.getProjectIteration());
CopyTransTaskHandle processHandle =
copyTransManager.getCopyTransProcessHandle(document);
if (processHandle == null) {
throw new NoSuchEntityException(
"There are no current or recently finished Copy Trans processes for this document.");
}
CopyTransStatus status = new CopyTransStatus();
status.setInProgress(!processHandle.isDone());
float percent =
((float) processHandle.getCurrentProgress() / processHandle
.getMaxProgress()) * 100;
status.setPercentageComplete((int) percent);
return status;
}