public class ServletContextResourceLoader
extends org.springframework.core.io.DefaultResourceLoader
Within a WebApplicationContext, resource paths are automatically resolved as ServletContext resources by the context implementation.
getResourceByPath(java.lang.String),
ServletContextResource,
WebApplicationContext,
org.springframework.web.servlet.HttpServletBean,
GenericFilterBean| Constructor and Description |
|---|
ServletContextResourceLoader(ServletContext servletContext)
Create a new ServletContextResourceLoader.
|
| Modifier and Type | Method and Description |
|---|---|
protected org.springframework.core.io.Resource |
getResourceByPath(String path)
This implementation supports file paths beneath the root of the web application.
|
public ServletContextResourceLoader(ServletContext servletContext)
servletContext - the ServletContext to load resources withprotected org.springframework.core.io.Resource getResourceByPath(String path)
getResourceByPath in class org.springframework.core.io.DefaultResourceLoaderServletContextResource