SessionConfig (Apache Tomcat 11.0.22 API Documentation)
Description: declaration: package: org.apache.tomcat.util.descriptor.web, class: SessionConfig

# Class SessionConfig

java.lang.Object
org.apache.tomcat.util.descriptor.web.SessionConfig

public class SessionConfig extends Object
Representation of a session configuration element for a web application, as represented in a `<session-config>` element in the deployment descriptor.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `SessionConfig()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `addSessionTrackingMode(String sessionTrackingMode)`
  `String`
  `getCookieAttribute(String name)`
  `Map<String,String>`
  `getCookieAttributes()`
  `String`
  `getCookieComment()`
  `String`
  `getCookieDomain()`
  `Boolean`
  `getCookieHttpOnly()`
  `Integer`
  `getCookieMaxAge()`
  `String`
  `getCookieName()`
  `String`
  `getCookiePath()`
  `Boolean`
  `getCookieSecure()`
  `Integer`
  `getSessionTimeout()`
  `EnumSet<SessionTrackingMode>`
  `getSessionTrackingModes()`
  `void`
  `setCookieAttribute(String name, String value)`
  `void`
  `setCookieComment(String cookieComment)`
  `void`
  `setCookieDomain(String cookieDomain)`
  `void`
  `setCookieHttpOnly(String cookieHttpOnly)`
  `void`
  `setCookieMaxAge(String cookieMaxAge)`
  `void`
  `setCookieName(String cookieName)`
  `void`
  `setCookiePath(String cookiePath)`
  `void`
  `setCookieSecure(String cookieSecure)`
  `void`
  `setSessionTimeout(String sessionTimeout)`

  ### Methods inherited from class Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### SessionConfig

    public SessionConfig()

- ## Method Details

  - ### getSessionTimeout

    public Integer getSessionTimeout()

  - ### setSessionTimeout

    public void setSessionTimeout(String sessionTimeout)

  - ### getCookieName

    public String getCookieName()

  - ### setCookieName

    public void setCookieName(String cookieName)

  - ### getCookieDomain

    public String getCookieDomain()

  - ### setCookieDomain

    public void setCookieDomain(String cookieDomain)

  - ### getCookiePath

    public String getCookiePath()

  - ### setCookiePath

    public void setCookiePath(String cookiePath)

  - ### getCookieComment

    public String getCookieComment()

  - ### setCookieComment

    public void setCookieComment(String cookieComment)

  - ### getCookieHttpOnly

    public Boolean getCookieHttpOnly()

  - ### setCookieHttpOnly

    public void setCookieHttpOnly(String cookieHttpOnly)

  - ### getCookieSecure

    public Boolean getCookieSecure()

  - ### setCookieSecure

    public void setCookieSecure(String cookieSecure)

  - ### getCookieMaxAge

    public Integer getCookieMaxAge()

  - ### setCookieMaxAge

    public void setCookieMaxAge(String cookieMaxAge)

  - ### getCookieAttributes

    public Map<String,String> getCookieAttributes()

  - ### setCookieAttribute

    public void setCookieAttribute(String name, String value)

  - ### getCookieAttribute

    public String getCookieAttribute(String name)

  - ### getSessionTrackingModes

    public EnumSet<SessionTrackingMode> getSessionTrackingModes()

  - ### addSessionTrackingMode

    public void addSessionTrackingMode(String sessionTrackingMode)