Stop referring to "Spring 3.x" features in documentation and code

This commit is contained in:
Sam Brannen
2023-01-20 11:44:34 +01:00
parent 8f94c4e933
commit 24f18275dd
39 changed files with 225 additions and 238 deletions

View File

@@ -424,7 +424,7 @@ public class MockHttpServletResponse implements HttpServletResponse {
buf.append("; Domain=").append(cookie.getDomain());
}
int maxAge = cookie.getMaxAge();
ZonedDateTime expires = (cookie instanceof MockCookie mockCookie? mockCookie.getExpires() : null);
ZonedDateTime expires = (cookie instanceof MockCookie mockCookie ? mockCookie.getExpires() : null);
if (maxAge >= 0) {
buf.append("; Max-Age=").append(maxAge);
buf.append("; Expires=");
@@ -491,12 +491,12 @@ public class MockHttpServletResponse implements HttpServletResponse {
/**
* Return the primary value for the given header as a String, if any.
* Will return the first value in case of multiple values.
* <p>As of Servlet 3.0, this method is also defined in {@link HttpServletResponse}.
* As of Spring 3.1, it returns a stringified value for Servlet 3.0 compatibility.
* Consider using {@link #getHeaderValue(String)} for raw Object access.
* <p>Will return the first value in case of multiple values.
* <p>Returns a stringified value for Servlet 3.0 compatibility. Consider
* using {@link #getHeaderValue(String)} for raw Object access.
* @param name the name of the header
* @return the associated header value, or {@code null} if none
* @see HttpServletResponse#getHeader(String)
*/
@Override
@Nullable
@@ -507,11 +507,11 @@ public class MockHttpServletResponse implements HttpServletResponse {
/**
* Return all values for the given header as a List of Strings.
* <p>As of Servlet 3.0, this method is also defined in {@link HttpServletResponse}.
* As of Spring 3.1, it returns a List of stringified values for Servlet 3.0 compatibility.
* <p>Returns a List of stringified values for Servlet 3.0 compatibility.
* Consider using {@link #getHeaderValues(String)} for raw Object access.
* @param name the name of the header
* @return the associated header values, or an empty List if none
* @see HttpServletResponse#getHeaders(String)
*/
@Override
public List<String> getHeaders(String name) {