ServerCookie (Apache Tomcat 10.1.48 API Documentation)
Description: declaration: package: org.apache.tomcat.util.http, class: ServerCookie

# Class ServerCookie

java.lang.Object
org.apache.tomcat.util.http.ServerCookie

All Implemented Interfaces:
  `Serializable`

public class ServerCookie extends Object implements Serializable
Server-side cookie representation. Allows recycling and uses MessageBytes as low-level representation ( and thus the byte -> char conversion can be delayed until we know the charset ).

Tomcat.core uses this recyclable object to represent cookies, and the facade will convert it to the external representation.

See Also:
  - Serialized Form

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ServerCookie()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `MessageBytes`
  `getName()`
  `MessageBytes`
  `getValue()`
  `void`
  `recycle()`
  `String`
  `toString()`

  ### Methods inherited from class Object

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

- ## Constructor Details

  - ### ServerCookie

    public ServerCookie()

- ## Method Details

  - ### recycle

    public void recycle()

  - ### getName

    public MessageBytes getName()

  - ### getValue

    public MessageBytes getValue()

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`