public class PathResourceResolver extends AbstractResourceResolver
ResourceResolver that tries to find a resource under the given
locations matching to the request path.
This resolver does not delegate to the ResourceResolverChain and is
expected to be configured at the end in a chain of resolvers.
logger| Constructor and Description |
|---|
PathResourceResolver() |
| Modifier and Type | Method and Description |
|---|---|
protected Resource |
getResource(String resourcePath,
Resource location)
Find the resource under the given location.
|
protected Resource |
resolveResourceInternal(HttpServletRequest request,
String requestPath,
List<? extends Resource> locations,
ResourceResolverChain chain) |
protected String |
resolveUrlPathInternal(String resourcePath,
List<? extends Resource> locations,
ResourceResolverChain chain) |
resolveResource, resolveUrlPathprotected Resource resolveResourceInternal(HttpServletRequest request, String requestPath, List<? extends Resource> locations, ResourceResolverChain chain)
resolveResourceInternal in class AbstractResourceResolverprotected String resolveUrlPathInternal(String resourcePath, List<? extends Resource> locations, ResourceResolverChain chain)
resolveUrlPathInternal in class AbstractResourceResolverprotected Resource getResource(String resourcePath, Resource location) throws IOException
The default implementation checks if there is a readable
Resource for the given path relative to the location.
resourcePath - the path to the resourcelocation - the location to checknullIOException