public final class HttpCookie extends HttpCookie implements ToStringRenderable, scala.Product, java.io.Serializable, scala.Equals
Constructor and Description |
---|
HttpCookie(java.lang.String name,
java.lang.String value,
scala.Option<DateTime> expires,
scala.Option<java.lang.Object> maxAge,
scala.Option<java.lang.String> domain,
scala.Option<java.lang.String> path,
boolean secure,
boolean httpOnly,
scala.Option<java.lang.String> extension)
Deprecated.
Please use HttpCookie(name, value).withXxx(). Since Akka HTTP 10.2.0.
|
HttpCookie(java.lang.String name,
java.lang.String value,
scala.Option<DateTime> expires,
scala.Option<java.lang.Object> maxAge,
scala.Option<java.lang.String> domain,
scala.Option<java.lang.String> path,
boolean secure,
boolean httpOnly,
scala.Option<java.lang.String> extension,
scala.Option<SameSite> sameSite) |
Modifier and Type | Method and Description |
---|---|
static HttpCookie |
apply(java.lang.String name,
java.lang.String value,
scala.Option<DateTime> expires,
scala.Option<java.lang.Object> maxAge,
scala.Option<java.lang.String> domain,
scala.Option<java.lang.String> path,
boolean secure,
boolean httpOnly,
scala.Option<java.lang.String> extension)
You are encouraged to provide only 'name' and 'value' here, and use
'withXxx' methods to populate other fields.
|
boolean |
canEqual(java.lang.Object that) |
HttpCookie |
copy(java.lang.String name,
java.lang.String value,
scala.Option<DateTime> expires,
scala.Option<java.lang.Object> maxAge,
scala.Option<java.lang.String> domain,
scala.Option<java.lang.String> path,
boolean secure,
boolean httpOnly,
scala.Option<java.lang.String> extension)
Deprecated.
for binary compatibility. Since Akka HTTP 10.2.0.
|
HttpCookie |
copy(java.lang.String name,
java.lang.String value,
scala.Option<DateTime> expires,
scala.Option<java.lang.Object> maxAge,
scala.Option<java.lang.String> domain,
scala.Option<java.lang.String> path,
boolean secure,
boolean httpOnly,
scala.Option<java.lang.String> extension,
scala.Option<SameSite> sameSite) |
scala.Option<java.lang.String> |
domain() |
static org.parboiled2.CharPredicate |
domainChars() |
boolean |
equals(java.lang.Object obj) |
scala.Option<DateTime> |
expires() |
scala.Option<java.lang.String> |
extension() |
static HttpCookie |
fromPair(HttpCookiePair pair,
scala.Option<DateTime> expires,
scala.Option<java.lang.Object> maxAge,
scala.Option<java.lang.String> domain,
scala.Option<java.lang.String> path,
boolean secure,
boolean httpOnly,
scala.Option<java.lang.String> extension)
Deprecated.
Use HttpCookiePair.toCookie and withXxx methods instead. Since Akka HTTP 10.2.0.
|
java.util.Optional<java.lang.String> |
getDomain()
Java API
|
java.util.Optional<DateTime> |
getExpires()
Java API
|
java.util.Optional<java.lang.String> |
getExtension()
Java API
|
java.util.OptionalLong |
getMaxAge()
Java API
|
java.util.Optional<java.lang.String> |
getPath()
Java API
|
java.util.Optional<SameSite> |
getSameSite()
Java API
|
boolean |
httpOnly() |
scala.Option<java.lang.Object> |
maxAge() |
java.lang.String |
name() |
static org.parboiled2.CharPredicate |
nameChars() |
HttpCookiePair |
pair()
Returns the name/value pair for this cookie, to be used in
Cookie headers. |
scala.Option<java.lang.String> |
path() |
static org.parboiled2.CharPredicate |
pathOrExtChars() |
int |
productArity() |
java.lang.Object |
productElement(int n) |
static org.parboiled2.CharPredicate |
rawValueChars() |
<R extends Rendering> |
render(R r) |
scala.Option<SameSite> |
sameSite() |
boolean |
secure() |
static scala.Option<scala.Tuple9<java.lang.String,java.lang.String,scala.Option<DateTime>,scala.Option<java.lang.Object>,scala.Option<java.lang.String>,scala.Option<java.lang.String>,java.lang.Object,java.lang.Object,scala.Option<java.lang.String>>> |
unapply(HttpCookie cookie)
Deprecated.
Pattern matching on HttpCookie is deprecated because of the big number of fields and potential future compatibility hazards. Please use other means to check the fields. Since Akka HTTP 10.2.0.
|
java.lang.String |
value() |
static org.parboiled2.CharPredicate |
valueChars()
http://tools.ietf.org/html/rfc6265#section-4.1.1
US-ASCII characters excluding CTLs, whitespace DQUOTE, comma, semicolon, and backslash
|
HttpCookie |
withDomain(java.lang.String domain)
Returns a copy of this HttpCookie instance with the given domain set.
|
HttpCookie |
withExpires(DateTime dateTime)
Scala API
|
HttpCookie |
withExpires(DateTime dateTime)
Java API
|
HttpCookie |
withExtension(java.lang.String extension)
Returns a copy of this HttpCookie instance with the given extension set.
|
HttpCookie |
withHttpOnly(boolean httpOnly)
Returns a copy of this HttpCookie instance with the given http-only flag set.
|
HttpCookie |
withMaxAge(long maxAge)
Returns a copy of this HttpCookie instance with the given max age set.
|
HttpCookie |
withName(java.lang.String name) |
HttpCookie |
withPath(java.lang.String path)
Returns a copy of this HttpCookie instance with the given path set.
|
HttpCookie |
withSameSite(scala.Option<SameSite> sameSite) |
HttpCookie |
withSameSite(java.util.Optional<SameSite> sameSite)
Returns a copy of this HttpCookie instance with the given Optional
SameSite set. |
HttpCookie |
withSameSite(SameSite sameSite)
Scala API
|
HttpCookie |
withSameSite(SameSite sameSite)
Java API
|
HttpCookie |
withSecure(boolean secure)
Returns a copy of this HttpCookie instance with the given secure flag set.
|
HttpCookie |
withValue(java.lang.String value) |
create, create, create, create
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
toString
public HttpCookie(java.lang.String name, java.lang.String value, scala.Option<DateTime> expires, scala.Option<java.lang.Object> maxAge, scala.Option<java.lang.String> domain, scala.Option<java.lang.String> path, boolean secure, boolean httpOnly, scala.Option<java.lang.String> extension, scala.Option<SameSite> sameSite)
public HttpCookie(java.lang.String name, java.lang.String value, scala.Option<DateTime> expires, scala.Option<java.lang.Object> maxAge, scala.Option<java.lang.String> domain, scala.Option<java.lang.String> path, boolean secure, boolean httpOnly, scala.Option<java.lang.String> extension)
public static HttpCookie apply(java.lang.String name, java.lang.String value, scala.Option<DateTime> expires, scala.Option<java.lang.Object> maxAge, scala.Option<java.lang.String> domain, scala.Option<java.lang.String> path, boolean secure, boolean httpOnly, scala.Option<java.lang.String> extension)
name
- (undocumented)value
- (undocumented)expires
- (undocumented)maxAge
- (undocumented)domain
- (undocumented)path
- (undocumented)secure
- (undocumented)httpOnly
- (undocumented)extension
- (undocumented)public static scala.Option<scala.Tuple9<java.lang.String,java.lang.String,scala.Option<DateTime>,scala.Option<java.lang.Object>,scala.Option<java.lang.String>,scala.Option<java.lang.String>,java.lang.Object,java.lang.Object,scala.Option<java.lang.String>>> unapply(HttpCookie cookie)
public static HttpCookie fromPair(HttpCookiePair pair, scala.Option<DateTime> expires, scala.Option<java.lang.Object> maxAge, scala.Option<java.lang.String> domain, scala.Option<java.lang.String> path, boolean secure, boolean httpOnly, scala.Option<java.lang.String> extension)
public static org.parboiled2.CharPredicate nameChars()
public static org.parboiled2.CharPredicate valueChars()
public static org.parboiled2.CharPredicate rawValueChars()
public static org.parboiled2.CharPredicate domainChars()
public static org.parboiled2.CharPredicate pathOrExtChars()
public java.lang.String name()
name
in class HttpCookie
public java.lang.String value()
value
in class HttpCookie
public scala.Option<DateTime> expires()
public scala.Option<java.lang.Object> maxAge()
public scala.Option<java.lang.String> domain()
public scala.Option<java.lang.String> path()
public boolean secure()
secure
in class HttpCookie
public boolean httpOnly()
httpOnly
in class HttpCookie
public scala.Option<java.lang.String> extension()
public scala.Option<SameSite> sameSite()
public HttpCookie copy(java.lang.String name, java.lang.String value, scala.Option<DateTime> expires, scala.Option<java.lang.Object> maxAge, scala.Option<java.lang.String> domain, scala.Option<java.lang.String> path, boolean secure, boolean httpOnly, scala.Option<java.lang.String> extension)
public HttpCookie copy(java.lang.String name, java.lang.String value, scala.Option<DateTime> expires, scala.Option<java.lang.Object> maxAge, scala.Option<java.lang.String> domain, scala.Option<java.lang.String> path, boolean secure, boolean httpOnly, scala.Option<java.lang.String> extension, scala.Option<SameSite> sameSite)
public int productArity()
productArity
in interface scala.Product
public java.lang.Object productElement(int n)
productElement
in interface scala.Product
public boolean canEqual(java.lang.Object that)
canEqual
in interface scala.Equals
public boolean equals(java.lang.Object obj)
equals
in interface scala.Equals
equals
in class java.lang.Object
public HttpCookiePair pair()
Cookie
headers.pair
in class HttpCookie
public <R extends Rendering> Rendering render(R r)
render
in interface Renderable
public java.util.Optional<SameSite> getSameSite()
getSameSite
in class HttpCookie
public java.util.Optional<java.lang.String> getExtension()
getExtension
in class HttpCookie
public java.util.Optional<java.lang.String> getPath()
getPath
in class HttpCookie
public java.util.Optional<java.lang.String> getDomain()
getDomain
in class HttpCookie
public java.util.OptionalLong getMaxAge()
getMaxAge
in class HttpCookie
public java.util.Optional<DateTime> getExpires()
getExpires
in class HttpCookie
public HttpCookie withName(java.lang.String name)
public HttpCookie withValue(java.lang.String value)
public HttpCookie withExpires(DateTime dateTime)
public HttpCookie withExpires(DateTime dateTime)
withExpires
in class HttpCookie
public HttpCookie withDomain(java.lang.String domain)
HttpCookie
withDomain
in class HttpCookie
public HttpCookie withPath(java.lang.String path)
HttpCookie
withPath
in class HttpCookie
public HttpCookie withMaxAge(long maxAge)
HttpCookie
withMaxAge
in class HttpCookie
public HttpCookie withSecure(boolean secure)
HttpCookie
withSecure
in class HttpCookie
public HttpCookie withHttpOnly(boolean httpOnly)
HttpCookie
withHttpOnly
in class HttpCookie
public HttpCookie withSameSite(SameSite sameSite)
public HttpCookie withSameSite(scala.Option<SameSite> sameSite)
public HttpCookie withSameSite(SameSite sameSite)
withSameSite
in class HttpCookie
public HttpCookie withSameSite(java.util.Optional<SameSite> sameSite)
HttpCookie
SameSite
set.withSameSite
in class HttpCookie
public HttpCookie withExtension(java.lang.String extension)
HttpCookie
withExtension
in class HttpCookie