Record Class HttpCookie

java.lang.Object
java.lang.Record
org.seppiko.commons.utils.http.HttpCookie
Record Components:
name - cookie name
value - cookie value

public record HttpCookie(String name, String value) extends Record
Http Cookie
Author:
Leonard Woo
See Also:
  • Constructor Details

    • HttpCookie

      public HttpCookie(String name, String value)
      Add a cookie
      Parameters:
      name - cookie name
      value - cookie value
  • Method Details

    • equals

      public boolean equals(Object o)
      check cookie is equals
      Specified by:
      equals in class Record
      Parameters:
      o - the reference object with which to compare.
      Returns:
      true if cookie is equal
    • hashCode

      public int hashCode()
      get cookie hashcode
      Specified by:
      hashCode in class Record
      Returns:
      hashcode
    • toString

      public String toString()
      get cookie pair string
      Specified by:
      toString in class Record
      Returns:
      cookie string
    • name

      public String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • value

      public String value()
      Returns the value of the value record component.
      Returns:
      the value of the value record component