import javax.jcr.security.AccessControlManager;
import javax.jcr.security.Privilege;
-import org.argeo.ArgeoException;
+import org.argeo.jcr.ArgeoJcrException;
import org.argeo.jcr.JcrUtils;
import org.argeo.util.security.SimplePrincipal;
}
} catch (Exception e) {
JcrUtils.discardQuietly(session);
- throw new ArgeoException(
+ throw new ArgeoJcrException(
"Cannot set authorizations " + principalPrivileges
+ " on workspace " + currentWorkspace, e);
} finally {
initAuthorizations(session);
} catch (Exception e) {
JcrUtils.discardQuietly(session);
- throw new ArgeoException("Cannot set authorizations "
+ throw new ArgeoJcrException("Cannot set authorizations "
+ principalPrivileges + " on repository " + repository, e);
} finally {
JcrUtils.logoutQuietly(session);
String path = null;
int slashIndex = privileges.indexOf('/');
if (slashIndex == 0) {
- throw new ArgeoException("Privilege " + privileges
+ throw new ArgeoJcrException("Privilege " + privileges
+ " badly formatted it starts with /");
} else if (slashIndex > 0) {
path = privileges.substring(slashIndex);
// + session.getWorkspace().getName() + "'");
// }
// } else {
- // throw new ArgeoException("Don't know how to apply privileges "
+ // throw new ArgeoJcrException("Don't know how to apply privileges "
// + privs + " to " + principal + " on " + path
// + " from workspace '" + session.getWorkspace().getName()
// + "'");