Class SessionUtil


  • public class SessionUtil
    extends java.lang.Object
    session Util - Spring에서 제공하는 RequestContextHolder 를 이용하여 request 객체를 service까지 전달하지 않고 사용할 수 있게 해줌
    • Constructor Summary

      Constructors 
      Constructor Description
      SessionUtil()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.Object getAttribute​(java.lang.String name)
      attribute 값을 가져 오기 위한 method
      static java.lang.String getSessionId()
      session id
      static javax.servlet.http.HttpServletRequest getUrl()  
      static void removeAttribute​(java.lang.String name)
      설정한 attribute 삭제
      static void setAttribute​(java.lang.String name, java.lang.Object object)
      attribute 설정 method
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SessionUtil

        public SessionUtil()
    • Method Detail

      • getAttribute

        public static java.lang.Object getAttribute​(java.lang.String name)
                                             throws java.lang.Exception
        attribute 값을 가져 오기 위한 method
        Throws:
        java.lang.Exception
      • setAttribute

        public static void setAttribute​(java.lang.String name,
                                        java.lang.Object object)
                                 throws java.lang.Exception
        attribute 설정 method
        Throws:
        java.lang.Exception
      • removeAttribute

        public static void removeAttribute​(java.lang.String name)
                                    throws java.lang.Exception
        설정한 attribute 삭제
        Throws:
        java.lang.Exception
      • getSessionId

        public static java.lang.String getSessionId()
                                             throws java.lang.Exception
        session id
        Throws:
        java.lang.Exception
      • getUrl

        public static javax.servlet.http.HttpServletRequest getUrl()
                                                            throws java.lang.Exception
        Throws:
        java.lang.Exception