return checkPermission(userSession.getUser(), view, right);
}
public boolean checkPermission(String sessionId, int right) throws SessionExpiredException {
AuthUser user = getLoggedInUser(sessionId);
Right rr = null;
switch (right) {
case 0: rr = Right.NONE; break;
case 1: rr = Right.READ; break;
case 2: rr = Right.WRITE; break;