Class ShiroHttpSession



  • public class ShiroHttpSession
    extends Object
    Wrapper class that uses a Shiro Session under the hood for all session operations instead of the Servlet Container's session mechanism. This is required in heterogeneous client environments where the Session is used on both the business tier as well as in multiple client technologies (web, swing, flash, etc) since Servlet container sessions alone cannot support this feature.
    Since:
    0.2
    • Field Detail

      • servletContext

        protected ServletContext servletContext
      • currentRequest

        protected HttpServletRequest currentRequest
      • session

        protected Session session
    • Constructor Detail

      • ShiroHttpSession

        public ShiroHttpSession(Session session,
                                HttpServletRequest currentRequest,
                                ServletContext servletContext)
    • Method Detail

      • getSession

        public Session getSession()
      • getCreationTime

        public long getCreationTime()
      • getId

        public String getId()
      • getLastAccessedTime

        public long getLastAccessedTime()
      • getServletContext

        public ServletContext getServletContext()
      • setMaxInactiveInterval

        public void setMaxInactiveInterval(int i)
      • getMaxInactiveInterval

        public int getMaxInactiveInterval()
      • getSessionContext

        public javax.servlet.http.HttpSessionContext getSessionContext()
      • getKeyNames

        protected Set<String> getKeyNames()
      • getAttributeNames

        public Enumeration getAttributeNames()
      • getValueNames

        public String[] getValueNames()
      • afterBound

        protected void afterBound(String s,
                                  Object o)
      • afterUnbound

        protected void afterUnbound(String s,
                                    Object o)
      • setAttribute

        public void setAttribute(String s,
                                 Object o)
      • removeAttribute

        public void removeAttribute(String s)
      • removeValue

        public void removeValue(String s)
      • invalidate

        public void invalidate()
      • isNew

        public boolean isNew()