Polishing
This commit is contained in:
@@ -93,12 +93,11 @@ public class ResourceHandlerRegistry {
|
||||
/**
|
||||
* A variant of
|
||||
* {@link #ResourceHandlerRegistry(ApplicationContext, ServletContext, ContentNegotiationManager)}
|
||||
* that also accepts the {@link UrlPathHelper} used for mapping requests
|
||||
* to static resources.
|
||||
* that also accepts the {@link UrlPathHelper} used for mapping requests to static resources.
|
||||
* @since 4.3.13
|
||||
*/
|
||||
public ResourceHandlerRegistry(ApplicationContext applicationContext, ServletContext servletContext,
|
||||
ContentNegotiationManager contentNegotiationManager, @Nullable UrlPathHelper pathHelper) {
|
||||
@Nullable ContentNegotiationManager contentNegotiationManager, @Nullable UrlPathHelper pathHelper) {
|
||||
|
||||
Assert.notNull(applicationContext, "ApplicationContext is required");
|
||||
this.applicationContext = applicationContext;
|
||||
@@ -109,13 +108,12 @@ public class ResourceHandlerRegistry {
|
||||
|
||||
|
||||
/**
|
||||
* Add a resource handler for serving static resources based on the specified URL path
|
||||
* patterns. The handler will be invoked for every incoming request that matches to
|
||||
* one of the specified path patterns.
|
||||
* <p>Patterns like {@code "/static/**"} or {@code "/css/{filename:\\w+\\.css}"}
|
||||
* are allowed. See {@link org.springframework.util.AntPathMatcher} for more details on the
|
||||
* syntax.
|
||||
* @return A {@link ResourceHandlerRegistration} to use to further configure the
|
||||
* Add a resource handler for serving static resources based on the specified URL path patterns.
|
||||
* The handler will be invoked for every incoming request that matches to one of the specified
|
||||
* path patterns.
|
||||
* <p>Patterns like {@code "/static/**"} or {@code "/css/{filename:\\w+\\.css}"} are allowed.
|
||||
* See {@link org.springframework.util.AntPathMatcher} for more details on the syntax.
|
||||
* @return a {@link ResourceHandlerRegistration} to use to further configure the
|
||||
* registered resource handler
|
||||
*/
|
||||
public ResourceHandlerRegistration addResourceHandler(String... pathPatterns) {
|
||||
|
||||
Reference in New Issue
Block a user