Class CookieHandler


  • public class CookieHandler
    extends org.springframework.web.util.CookieGenerator
    • Field Summary

      • Fields inherited from class org.springframework.web.util.CookieGenerator

        DEFAULT_COOKIE_PATH, logger
    • Constructor Summary

      Constructors 
      Constructor Description
      CookieHandler()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addCookie​(javax.servlet.http.HttpServletResponse response, String cookieValue, Integer maxAge)
      Add a cookie with the given value and age to the response, using the cookie descriptor settings of this generator.
      protected javax.servlet.http.Cookie createCookie​(String cookieValue)
      don't set domain when it is empty
      javax.servlet.http.Cookie get​(javax.servlet.http.HttpServletRequest request)  
      String getValue​(javax.servlet.http.HttpServletRequest request)  
      • Methods inherited from class org.springframework.web.util.CookieGenerator

        addCookie, getCookieDomain, getCookieMaxAge, getCookieName, getCookiePath, isCookieHttpOnly, isCookieSecure, removeCookie, setCookieDomain, setCookieHttpOnly, setCookieMaxAge, setCookieName, setCookiePath, setCookieSecure
    • Constructor Detail

      • CookieHandler

        public CookieHandler()
    • Method Detail

      • get

        public javax.servlet.http.Cookie get​(javax.servlet.http.HttpServletRequest request)
      • getValue

        public String getValue​(javax.servlet.http.HttpServletRequest request)
      • createCookie

        protected javax.servlet.http.Cookie createCookie​(String cookieValue)
        don't set domain when it is empty
        Overrides:
        createCookie in class org.springframework.web.util.CookieGenerator
      • addCookie

        public void addCookie​(javax.servlet.http.HttpServletResponse response,
                              String cookieValue,
                              Integer maxAge)
        Add a cookie with the given value and age to the response, using the cookie descriptor settings of this generator.
        Parameters:
        response - the HTTP response to add the cookie to
        cookieValue - the value of the cookie to add
        maxAge - max age value of the cookie to add