Package akka.http.javadsl.model.headers
Class HttpCookie
java.lang.Object
akka.http.javadsl.model.headers.HttpCookie
- Direct Known Subclasses:
HttpCookie
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic HttpCookie
static HttpCookie
create
(String name, String value, Optional<DateTime> expires, OptionalLong maxAge, Optional<String> domain, Optional<String> path, boolean secure, boolean httpOnly, Optional<String> extension) Deprecated.Since 10.2.0.static HttpCookie
create
(String name, String value, Optional<DateTime> expires, OptionalLong maxAge, Optional<String> domain, Optional<String> path, boolean secure, boolean httpOnly, Optional<String> extension, Optional<SameSite> sameSite) static HttpCookie
abstract OptionalLong
getPath()
abstract boolean
httpOnly()
abstract String
name()
abstract HttpCookiePair
pair()
abstract boolean
secure()
abstract String
value()
abstract HttpCookie
withDomain
(String domain) Returns a copy of this HttpCookie instance with the given domain set.abstract HttpCookie
withExpires
(DateTime dateTime) Returns a copy of this HttpCookie instance with the given expiration set.abstract HttpCookie
withExtension
(String extension) Returns a copy of this HttpCookie instance with the given extension set.abstract HttpCookie
withHttpOnly
(boolean httpOnly) Returns a copy of this HttpCookie instance with the given http-only flag set.abstract HttpCookie
withMaxAge
(long maxAge) Returns a copy of this HttpCookie instance with the given max age set.abstract HttpCookie
Returns a copy of this HttpCookie instance with the given path set.abstract HttpCookie
withSameSite
(SameSite sameSite) Returns a copy of this HttpCookie instance with the givenSameSite
set.abstract HttpCookie
withSameSite
(Optional<SameSite> sameSite) Returns a copy of this HttpCookie instance with the given OptionalSameSite
set.abstract HttpCookie
withSecure
(boolean secure) Returns a copy of this HttpCookie instance with the given secure flag set.
-
Constructor Details
-
HttpCookie
public HttpCookie()
-
-
Method Details
-
name
-
value
-
pair
-
getExpires
-
getMaxAge
-
getDomain
-
getPath
-
secure
public abstract boolean secure() -
httpOnly
public abstract boolean httpOnly() -
getExtension
-
getSameSite
-
create
-
create
-
create
public static HttpCookie create(String name, String value, Optional<DateTime> expires, OptionalLong maxAge, Optional<String> domain, Optional<String> path, boolean secure, boolean httpOnly, Optional<String> extension) Deprecated.Since 10.2.0. Usecreate(String, String, Optional, OptionalLong, Optional, Optional, boolean, boolean, Optional, Optional)
instead. -
create
-
withExpires
Returns a copy of this HttpCookie instance with the given expiration set. -
withMaxAge
Returns a copy of this HttpCookie instance with the given max age set. -
withDomain
Returns a copy of this HttpCookie instance with the given domain set. -
withPath
Returns a copy of this HttpCookie instance with the given path set. -
withSecure
Returns a copy of this HttpCookie instance with the given secure flag set. -
withHttpOnly
Returns a copy of this HttpCookie instance with the given http-only flag set. -
withSameSite
Returns a copy of this HttpCookie instance with the givenSameSite
set. -
withSameSite
Returns a copy of this HttpCookie instance with the given OptionalSameSite
set. -
withExtension
Returns a copy of this HttpCookie instance with the given extension set.
-