Skip to content

Commit 6efe3ae

Browse files
committed
Polishing
1 parent f2fe7f3 commit 6efe3ae

File tree

3 files changed

+18
-17
lines changed

3 files changed

+18
-17
lines changed

spring-web/src/main/java/org/springframework/web/server/session/CookieWebSessionIdResolver.java

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2018 the original author or authors.
2+
* Copyright 2002-2022 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -47,7 +47,7 @@ public class CookieWebSessionIdResolver implements WebSessionIdResolver {
4747

4848

4949
/**
50-
* Set the name of the cookie to use for the session id.
50+
* Set the name of the cookie to use for the session ID.
5151
* <p>By default set to "SESSION".
5252
* @param cookieName the cookie name
5353
*/
@@ -57,15 +57,16 @@ public void setCookieName(String cookieName) {
5757
}
5858

5959
/**
60-
* Return the configured cookie name.
60+
* Get the configured cookie name.
6161
*/
6262
public String getCookieName() {
6363
return this.cookieName;
6464
}
6565

6666
/**
6767
* Set the value for the "Max-Age" attribute of the cookie that holds the
68-
* session id. For the range of values see {@link ResponseCookie#getMaxAge()}.
68+
* session ID.
69+
* <p>For the range of values see {@link ResponseCookie#getMaxAge()}.
6970
* <p>By default set to -1.
7071
* @param maxAge the maxAge duration value
7172
*/
@@ -74,7 +75,7 @@ public void setCookieMaxAge(Duration maxAge) {
7475
}
7576

7677
/**
77-
* Return the configured "Max-Age" attribute value for the session cookie.
78+
* Get the configured "Max-Age" attribute value for the session cookie.
7879
*/
7980
public Duration getCookieMaxAge() {
8081
return this.cookieMaxAge;

spring-web/src/main/java/org/springframework/web/server/session/HeaderWebSessionIdResolver.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2018 the original author or authors.
2+
* Copyright 2002-2022 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -40,9 +40,9 @@ public class HeaderWebSessionIdResolver implements WebSessionIdResolver {
4040

4141

4242
/**
43-
* Set the name of the session header to use for the session id.
44-
* The name is used to extract the session id from the request headers as
45-
* well to set the session id on the response headers.
43+
* Set the name of the session header to use for the session ID.
44+
* <p>The name is used to extract the session ID from the request headers as
45+
* well to set the session ID on the response headers.
4646
* <p>By default set to {@code DEFAULT_HEADER_NAME}
4747
* @param headerName the header name
4848
*/
@@ -52,7 +52,7 @@ public void setHeaderName(String headerName) {
5252
}
5353

5454
/**
55-
* Return the configured header name.
55+
* Get the configured header name.
5656
* @return the configured header name
5757
*/
5858
public String getHeaderName() {

spring-web/src/main/java/org/springframework/web/server/session/WebSessionIdResolver.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2016 the original author or authors.
2+
* Copyright 2002-2022 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -21,8 +21,8 @@
2121
import org.springframework.web.server.ServerWebExchange;
2222

2323
/**
24-
* Contract for session id resolution strategies. Allows for session id
25-
* resolution through the request and for sending the session id or expiring
24+
* Contract for session ID resolution strategies. Allows for session ID
25+
* resolution through the request and for sending the session ID or expiring
2626
* the session through the response.
2727
*
2828
* @author Rossen Stoyanchev
@@ -32,16 +32,16 @@
3232
public interface WebSessionIdResolver {
3333

3434
/**
35-
* Resolve the session id's associated with the request.
35+
* Resolve the session IDs associated with the request.
3636
* @param exchange the current exchange
37-
* @return the session id's or an empty list
37+
* @return the session IDs or an empty list
3838
*/
3939
List<String> resolveSessionIds(ServerWebExchange exchange);
4040

4141
/**
42-
* Send the given session id to the client.
42+
* Send the given session ID to the client.
4343
* @param exchange the current exchange
44-
* @param sessionId the session id
44+
* @param sessionId the session ID
4545
*/
4646
void setSessionId(ServerWebExchange exchange, String sessionId);
4747

0 commit comments

Comments
 (0)