%@ page import="org.apache.struts.util.MessageResources, org.apache.struts.Globals, org.apache.agila.bpel.client.User, java.util.Set"%> <%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html"%> <%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic"%> <%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%> <%@ taglib uri="/WEB-INF/struts-tiles.tld" prefix="tiles" %> <%! public String getMenuItemStyle(HttpServletRequest request, String item, String value) { String msg = ((MessageResources)request.getAttribute(Globals.MESSAGES_KEY)).getMessage(value); if(msg == null) { msg = value; } HttpSession session = request.getSession(); String boldMenu = (String) session.getAttribute("currentMenu"); if(item.equals(boldMenu)) { return ""+msg+""; } else { return msg; } } public boolean isUserInRole(HttpServletRequest request, String rolename) { Set roles = (Set) request.getSession().getAttribute("rolesName"); if(roles == null) { return false; } return roles.contains(rolename); } %>