logger.debug("IN: documentId = [" + documentId + "]; template file name = [" + sdkTemplate.getFileName() + "]");
try {
IEngUserProfile profile = getUserProfile();
// if user cannot develop the specified document, he cannot upload templates on it
if (!ObjectsAccessVerifier.canDevBIObject(documentId, profile)) {
NotAllowedOperationException e = new NotAllowedOperationException();
e.setFaultString("User cannot upload templates on specified document since he cannot develop it.");
throw e;
}
ObjTemplate objTemplate = new SDKObjectsConverter().fromSDKTemplateToObjTemplate(sdkTemplate);
objTemplate.setBiobjId(documentId);
objTemplate.setActive(new Boolean(true));