Class ServletCookieAdaptor

  • All Implemented Interfaces:
    io.undertow.server.handlers.Cookie, java.lang.Comparable

    public class ServletCookieAdaptor
    extends java.lang.Object
    implements io.undertow.server.handlers.Cookie
    Adaptor between and undertow and a servlet cookie
    Author:
    Stuart Douglas, Richard Opalka
    • Constructor Summary

      Constructors 
      Constructor Description
      ServletCookieAdaptor​(jakarta.servlet.http.Cookie cookie)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int compareTo​(java.lang.Object other)  
      boolean equals​(java.lang.Object other)  
      java.lang.String getComment()  
      java.lang.String getDomain()  
      java.util.Date getExpires()  
      java.lang.Integer getMaxAge()  
      java.lang.String getName()  
      java.lang.String getPath()  
      java.lang.String getSameSiteMode()  
      java.lang.String getValue()  
      int getVersion()  
      int hashCode()  
      boolean isDiscard()  
      boolean isHttpOnly()  
      boolean isSameSite()  
      boolean isSecure()  
      io.undertow.server.handlers.Cookie setComment​(java.lang.String comment)  
      io.undertow.server.handlers.Cookie setDiscard​(boolean discard)  
      io.undertow.server.handlers.Cookie setDomain​(java.lang.String domain)  
      io.undertow.server.handlers.Cookie setExpires​(java.util.Date expires)  
      io.undertow.server.handlers.Cookie setHttpOnly​(boolean httpOnly)  
      io.undertow.server.handlers.Cookie setMaxAge​(java.lang.Integer maxAge)  
      io.undertow.server.handlers.Cookie setPath​(java.lang.String path)  
      io.undertow.server.handlers.Cookie setSameSite​(boolean sameSite)  
      io.undertow.server.handlers.Cookie setSameSiteMode​(java.lang.String mode)  
      io.undertow.server.handlers.Cookie setSecure​(boolean secure)  
      io.undertow.server.handlers.Cookie setValue​(java.lang.String value)  
      io.undertow.server.handlers.Cookie setVersion​(int version)  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • ServletCookieAdaptor

        public ServletCookieAdaptor​(jakarta.servlet.http.Cookie cookie)
    • Method Detail

      • getName

        public java.lang.String getName()
        Specified by:
        getName in interface io.undertow.server.handlers.Cookie
      • getValue

        public java.lang.String getValue()
        Specified by:
        getValue in interface io.undertow.server.handlers.Cookie
      • setValue

        public io.undertow.server.handlers.Cookie setValue​(java.lang.String value)
        Specified by:
        setValue in interface io.undertow.server.handlers.Cookie
      • getPath

        public java.lang.String getPath()
        Specified by:
        getPath in interface io.undertow.server.handlers.Cookie
      • setPath

        public io.undertow.server.handlers.Cookie setPath​(java.lang.String path)
        Specified by:
        setPath in interface io.undertow.server.handlers.Cookie
      • getDomain

        public java.lang.String getDomain()
        Specified by:
        getDomain in interface io.undertow.server.handlers.Cookie
      • setDomain

        public io.undertow.server.handlers.Cookie setDomain​(java.lang.String domain)
        Specified by:
        setDomain in interface io.undertow.server.handlers.Cookie
      • getMaxAge

        public java.lang.Integer getMaxAge()
        Specified by:
        getMaxAge in interface io.undertow.server.handlers.Cookie
      • setMaxAge

        public io.undertow.server.handlers.Cookie setMaxAge​(java.lang.Integer maxAge)
        Specified by:
        setMaxAge in interface io.undertow.server.handlers.Cookie
      • isDiscard

        public boolean isDiscard()
        Specified by:
        isDiscard in interface io.undertow.server.handlers.Cookie
      • setDiscard

        public io.undertow.server.handlers.Cookie setDiscard​(boolean discard)
        Specified by:
        setDiscard in interface io.undertow.server.handlers.Cookie
      • isSecure

        public boolean isSecure()
        Specified by:
        isSecure in interface io.undertow.server.handlers.Cookie
      • setSecure

        public io.undertow.server.handlers.Cookie setSecure​(boolean secure)
        Specified by:
        setSecure in interface io.undertow.server.handlers.Cookie
      • getVersion

        public int getVersion()
        Specified by:
        getVersion in interface io.undertow.server.handlers.Cookie
      • setVersion

        public io.undertow.server.handlers.Cookie setVersion​(int version)
        Specified by:
        setVersion in interface io.undertow.server.handlers.Cookie
      • isHttpOnly

        public boolean isHttpOnly()
        Specified by:
        isHttpOnly in interface io.undertow.server.handlers.Cookie
      • setHttpOnly

        public io.undertow.server.handlers.Cookie setHttpOnly​(boolean httpOnly)
        Specified by:
        setHttpOnly in interface io.undertow.server.handlers.Cookie
      • getExpires

        public java.util.Date getExpires()
        Specified by:
        getExpires in interface io.undertow.server.handlers.Cookie
      • setExpires

        public io.undertow.server.handlers.Cookie setExpires​(java.util.Date expires)
        Specified by:
        setExpires in interface io.undertow.server.handlers.Cookie
      • getComment

        public java.lang.String getComment()
        Specified by:
        getComment in interface io.undertow.server.handlers.Cookie
      • setComment

        public io.undertow.server.handlers.Cookie setComment​(java.lang.String comment)
        Specified by:
        setComment in interface io.undertow.server.handlers.Cookie
      • isSameSite

        public boolean isSameSite()
        Specified by:
        isSameSite in interface io.undertow.server.handlers.Cookie
      • setSameSite

        public io.undertow.server.handlers.Cookie setSameSite​(boolean sameSite)
        Specified by:
        setSameSite in interface io.undertow.server.handlers.Cookie
      • getSameSiteMode

        public java.lang.String getSameSiteMode()
        Specified by:
        getSameSiteMode in interface io.undertow.server.handlers.Cookie
      • setSameSiteMode

        public io.undertow.server.handlers.Cookie setSameSiteMode​(java.lang.String mode)
        Specified by:
        setSameSiteMode in interface io.undertow.server.handlers.Cookie
      • hashCode

        public final int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public final boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object
      • compareTo

        public final int compareTo​(java.lang.Object other)
        Specified by:
        compareTo in interface java.lang.Comparable
        Specified by:
        compareTo in interface io.undertow.server.handlers.Cookie
      • toString

        public final java.lang.String toString()
        Overrides:
        toString in class java.lang.Object