Package | Description |
---|---|
org.springframework.http |
Contains a basic abstraction over client/server-side HTTP.
|
org.springframework.web.server.session |
Auxiliary interfaces and implementation classes for
WebSession support. |
Modifier and Type | Method and Description |
---|---|
ResponseCookie.ResponseCookieBuilder |
ResponseCookie.ResponseCookieBuilder.domain(String domain)
Set the cookie "Domain" attribute.
|
static ResponseCookie.ResponseCookieBuilder |
ResponseCookie.from(String name,
String value)
Factory method to obtain a builder for a server-defined cookie that starts
with a name-value pair and may also include attributes.
|
static ResponseCookie.ResponseCookieBuilder |
ResponseCookie.fromClientResponse(String name,
String value)
Factory method to obtain a builder for a server-defined cookie.
|
ResponseCookie.ResponseCookieBuilder |
ResponseCookie.ResponseCookieBuilder.httpOnly(boolean httpOnly)
Add the "HttpOnly" attribute to the cookie.
|
ResponseCookie.ResponseCookieBuilder |
ResponseCookie.ResponseCookieBuilder.maxAge(Duration maxAge)
Set the cookie "Max-Age" attribute.
|
ResponseCookie.ResponseCookieBuilder |
ResponseCookie.ResponseCookieBuilder.maxAge(long maxAgeSeconds)
Variant of
maxAge(Duration) accepting a value in seconds. |
ResponseCookie.ResponseCookieBuilder |
ResponseCookie.ResponseCookieBuilder.path(String path)
Set the cookie "Path" attribute.
|
ResponseCookie.ResponseCookieBuilder |
ResponseCookie.ResponseCookieBuilder.sameSite(String sameSite)
Add the "SameSite" attribute to the cookie.
|
ResponseCookie.ResponseCookieBuilder |
ResponseCookie.ResponseCookieBuilder.secure(boolean secure)
Add the "Secure" attribute to the cookie.
|
Modifier and Type | Method and Description |
---|---|
void |
CookieWebSessionIdResolver.addCookieInitializer(Consumer<ResponseCookie.ResponseCookieBuilder> initializer)
Add a
Consumer for a ResponseCookieBuilder that will be invoked
for each cookie being built, just before the call to build() . |