Class AbstractCookieConfiguration

  • All Implemented Interfaces:
    io.micronaut.http.cookie.CookieConfiguration
    Direct Known Subclasses:
    CookieNoncePersistenceConfiguration, CookieStatePersistenceConfiguration

    public abstract class AbstractCookieConfiguration
    extends java.lang.Object
    implements io.micronaut.http.cookie.CookieConfiguration
    Base configuration for CookieConfiguration implementations.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.lang.String cookieDomain  
      protected java.lang.Boolean cookieSecure  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Optional<java.lang.String> getCookieDomain()  
      java.util.Optional<java.lang.Boolean> isCookieSecure()  
      void setCookieDomain​(java.lang.String cookieDomain)
      Sets the domain name of this Cookie.
      void setCookieSecure​(java.lang.Boolean cookieSecure)
      Sets whether the cookie is secured.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface io.micronaut.http.cookie.CookieConfiguration

        getCookieMaxAge, getCookieName, getCookiePath, getCookieSameSite, isCookieHttpOnly
    • Field Detail

      • cookieDomain

        protected java.lang.String cookieDomain
      • cookieSecure

        protected java.lang.Boolean cookieSecure
    • Constructor Detail

      • AbstractCookieConfiguration

        public AbstractCookieConfiguration()
    • Method Detail

      • getCookieDomain

        public java.util.Optional<java.lang.String> getCookieDomain()
        Specified by:
        getCookieDomain in interface io.micronaut.http.cookie.CookieConfiguration
      • setCookieDomain

        public void setCookieDomain​(@Nullable
                                    java.lang.String cookieDomain)
        Sets the domain name of this Cookie. Default value (null).
        Parameters:
        cookieDomain - the domain name of this Cookie
      • isCookieSecure

        public java.util.Optional<java.lang.Boolean> isCookieSecure()
        Specified by:
        isCookieSecure in interface io.micronaut.http.cookie.CookieConfiguration
      • setCookieSecure

        public void setCookieSecure​(java.lang.Boolean cookieSecure)
        Sets whether the cookie is secured. Defaults to the secure status of the request.
        Parameters:
        cookieSecure - True if the cookie is secure