/** * List access. * * @return the response * @throws AccessException * the access exception */ @GET @Path("/access") public Response listAccess() throws AccessException { String user = UserFacade.getName(); if (user == null) { sendErrorForbidden(response, NO_LOGGED_IN_USER); return Response.status(Status.FORBIDDEN).build(); } return Response.ok().entity(processor.renderAccess()).type(ContentTypeHelper.APPLICATION_JSON).build(); }
/** * List roles. * * @return the response * @throws AccessException * the access exception */ @GET @Path("/roles") public Response listRoles() throws AccessException { String user = UserFacade.getName(); if (user == null) { sendErrorForbidden(response, NO_LOGGED_IN_USER); return Response.status(Status.FORBIDDEN).build(); } return Response.ok().entity(processor.renderRoles()).type(ContentTypeHelper.APPLICATION_JSON).build(); }
/** * List access. * * @return the response * @throws AccessException * the access exception */ @GET @Path("/access") public Response listSecurityAccess() throws AccessException { String user = UserFacade.getName(); if (user == null) { sendErrorForbidden(response, NO_LOGGED_IN_USER); return Response.status(Status.FORBIDDEN).build(); } return Response.ok().entity(processor.renderAccess()).type(ContentTypeHelper.APPLICATION_JSON).build(); }
/** * List roles. * * @return the response * @throws AccessException * the access exception */ @GET @Path("/roles") public Response listSecurityRoles() throws AccessException { String user = UserFacade.getName(); if (user == null) { sendErrorForbidden(response, NO_LOGGED_IN_USER); return Response.status(Status.FORBIDDEN).build(); } return Response.ok().entity(processor.renderRoles()).type(ContentTypeHelper.APPLICATION_JSON).build(); }