From bed4d684e678f36ca3c0672eabdff9259ae6692b Mon Sep 17 00:00:00 2001 From: yuhangbin Date: Fri, 23 Feb 2024 09:53:42 +0800 Subject: [PATCH] Polishing --- .../web/servlet/mvc/ParameterizableViewController.java | 2 +- .../web/servlet/resource/EncodedResourceResolver.java | 2 +- .../web/servlet/resource/ResourceHttpRequestHandler.java | 2 +- .../web/servlet/resource/ResourceUrlProvider.java | 2 +- .../web/servlet/view/AbstractUrlBasedView.java | 2 +- .../java/org/springframework/web/servlet/view/JstlView.java | 4 ++-- .../org/springframework/web/servlet/view/RedirectView.java | 2 +- 7 files changed, 8 insertions(+), 8 deletions(-) diff --git a/spring-webmvc/src/main/java/org/springframework/web/servlet/mvc/ParameterizableViewController.java b/spring-webmvc/src/main/java/org/springframework/web/servlet/mvc/ParameterizableViewController.java index 33dbf0defff..9bbf9af4f38 100644 --- a/spring-webmvc/src/main/java/org/springframework/web/servlet/mvc/ParameterizableViewController.java +++ b/spring-webmvc/src/main/java/org/springframework/web/servlet/mvc/ParameterizableViewController.java @@ -102,7 +102,7 @@ public class ParameterizableViewController extends AbstractController { * Configure the HTTP status code that this controller should set on the * response. *

When a "redirect:" prefixed view name is configured, there is no need - * to set this property since RedirectView will do that. However this property + * to set this property since RedirectView will do that. However, this property * may still be used to override the 3xx status code of {@code RedirectView}. * For full control over redirecting provide a {@code RedirectView} instance. *

If the status code is 204 and no view is configured, the request is diff --git a/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/EncodedResourceResolver.java b/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/EncodedResourceResolver.java index fcb3292bb6d..73a37745154 100644 --- a/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/EncodedResourceResolver.java +++ b/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/EncodedResourceResolver.java @@ -79,7 +79,7 @@ public class EncodedResourceResolver extends AbstractResourceResolver { * given request, and that has a file present with the associated extension, * is used. *

Note: Each coding must be associated with a file - * extension via {@link #registerExtension} or {@link #setExtensions}. Also + * extension via {@link #registerExtension} or {@link #setExtensions}. Also, * customizations to the list of codings here should be matched by * customizations to the same list in {@link CachingResourceResolver} to * ensure encoded variants of a resource are cached under separate keys. diff --git a/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/ResourceHttpRequestHandler.java b/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/ResourceHttpRequestHandler.java index 23726ae4dba..8d0a10218af 100644 --- a/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/ResourceHttpRequestHandler.java +++ b/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/ResourceHttpRequestHandler.java @@ -164,7 +164,7 @@ public class ResourceHttpRequestHandler extends WebContentGenerator * {@code /META-INF/public-web-resources/} directory, with resources in the * web application root taking precedence. *

For {@link org.springframework.core.io.UrlResource URL-based resources} - * (e.g. files, HTTP URLs, etc) this method supports a special prefix to + * (e.g. files, HTTP URLs, etc.) this method supports a special prefix to * indicate the charset associated with the URL so that relative paths * appended to it can be encoded correctly, for example * {@code "[charset=Windows-31J]https://example.org/path"}. diff --git a/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/ResourceUrlProvider.java b/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/ResourceUrlProvider.java index 62b7fd43a6f..0b8994b2534 100644 --- a/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/ResourceUrlProvider.java +++ b/spring-webmvc/src/main/java/org/springframework/web/servlet/resource/ResourceUrlProvider.java @@ -107,7 +107,7 @@ public class ResourceUrlProvider implements ApplicationListenerNote: by default resource mappings are auto-detected - * from the Spring {@code ApplicationContext}. However if this property is + * from the Spring {@code ApplicationContext}. However, if this property is * used, the auto-detection is turned off. */ public void setHandlerMap(@Nullable Map handlerMap) { diff --git a/spring-webmvc/src/main/java/org/springframework/web/servlet/view/AbstractUrlBasedView.java b/spring-webmvc/src/main/java/org/springframework/web/servlet/view/AbstractUrlBasedView.java index 97a452ee608..f6f7558b623 100644 --- a/spring-webmvc/src/main/java/org/springframework/web/servlet/view/AbstractUrlBasedView.java +++ b/spring-webmvc/src/main/java/org/springframework/web/servlet/view/AbstractUrlBasedView.java @@ -23,7 +23,7 @@ import org.springframework.lang.Nullable; /** * Abstract base class for URL-based views. Provides a consistent way of - * holding the URL that a View wraps, in the form of a "url" bean property. + * holding the URL that a View wraps, in the form of an "url" bean property. * * @author Juergen Hoeller * @since 13.12.2003 diff --git a/spring-webmvc/src/main/java/org/springframework/web/servlet/view/JstlView.java b/spring-webmvc/src/main/java/org/springframework/web/servlet/view/JstlView.java index 01535be6486..b18c8089e23 100644 --- a/spring-webmvc/src/main/java/org/springframework/web/servlet/view/JstlView.java +++ b/spring-webmvc/src/main/java/org/springframework/web/servlet/view/JstlView.java @@ -50,9 +50,9 @@ import org.springframework.web.servlet.support.RequestContext; * resource (for example: "myView" → "/WEB-INF/jsp/myView.jsp"), using * this view class to enable explicit JSTL support. * - *

The specified MessageSource loads messages from "messages.properties" etc + *

The specified MessageSource loads messages from "messages.properties" etc. * files in the class path. This will automatically be exposed to views as - * JSTL localization context, which the JSTL fmt tags (message etc) will use. + * JSTL localization context, which the JSTL fmt tags (message etc.) will use. * Consider using Spring's ReloadableResourceBundleMessageSource instead of * the standard ResourceBundleMessageSource for more sophistication. * Of course, any other Spring components can share the same MessageSource. diff --git a/spring-webmvc/src/main/java/org/springframework/web/servlet/view/RedirectView.java b/spring-webmvc/src/main/java/org/springframework/web/servlet/view/RedirectView.java index 6cbbb19c41a..2db8c7d38a1 100644 --- a/spring-webmvc/src/main/java/org/springframework/web/servlet/view/RedirectView.java +++ b/spring-webmvc/src/main/java/org/springframework/web/servlet/view/RedirectView.java @@ -554,7 +554,7 @@ public class RedirectView extends AbstractUrlBasedView implements SmartView { /** * Determine whether the given model element value is eligible for exposure. *

The default implementation considers primitives, strings, numbers, dates, - * URIs, URLs etc as eligible, according to {@link BeanUtils#isSimpleValueType}. + * URIs, URLs etc. as eligible, according to {@link BeanUtils#isSimpleValueType}. * This can be overridden in subclasses. * @param value the model element value * @return whether the element value is eligible