public class AssetLocatorImpl extends org.springframework.web.servlet.resource.AbstractResourceResolver implements AssetLocator, org.springframework.beans.factory.InitializingBean
| Constructor and Description |
|---|
AssetLocatorImpl() |
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet() |
Collection<String> |
getAssets() |
Collection<String> |
getAssets(boolean minified) |
static AssetLocator |
getInstance() |
long |
getReloadMinutes() |
protected org.springframework.core.io.Resource |
getResource(String requestPath,
List<? extends org.springframework.core.io.Resource> locations) |
Optional<AssetResource> |
getResource(String assetName,
String type) |
Optional<AssetResource> |
getResource(String assetName,
String type,
boolean minified) |
Optional<Collection<AssetResource>> |
getResources(String assetName) |
Optional<Collection<AssetResource>> |
getResources(String assetName,
boolean minified) |
boolean |
getUseMinified() |
long |
lastModified() |
Optional<InputStream> |
open(String assetName,
String type) |
Optional<InputStream> |
open(String assetName,
String type,
boolean minified) |
void |
reload() |
protected org.springframework.core.io.Resource |
resolveResourceInternal(javax.servlet.http.HttpServletRequest request,
String requestPath,
List<? extends org.springframework.core.io.Resource> locations,
org.springframework.web.servlet.resource.ResourceResolverChain chain) |
protected String |
resolveUrlPathInternal(String resourcePath,
List<? extends org.springframework.core.io.Resource> locations,
org.springframework.web.servlet.resource.ResourceResolverChain chain) |
void |
setReloadMinutes(long minutes) |
void |
setUseMinified(boolean minified) |
resolveResource, resolveUrlPathpublic static AssetLocator getInstance()
public long lastModified()
lastModified in interface AssetLocatorpublic Collection<String> getAssets()
getAssets in interface AssetLocatorpublic Collection<String> getAssets(boolean minified)
getAssets in interface AssetLocatorpublic Optional<Collection<AssetResource>> getResources(String assetName)
getResources in interface AssetLocatorpublic Optional<Collection<AssetResource>> getResources(String assetName, boolean minified)
getResources in interface AssetLocatorpublic Optional<AssetResource> getResource(String assetName, String type)
getResource in interface AssetLocatorpublic Optional<AssetResource> getResource(String assetName, String type, boolean minified)
getResource in interface AssetLocatorpublic Optional<InputStream> open(String assetName, String type) throws IOException
open in interface AssetLocatorIOExceptionpublic Optional<InputStream> open(String assetName, String type, boolean minified) throws IOException
open in interface AssetLocatorIOExceptionpublic void reload()
reload in interface AssetLocatorpublic void afterPropertiesSet()
throws Exception
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanExceptionpublic long getReloadMinutes()
public void setReloadMinutes(long minutes)
public boolean getUseMinified()
public void setUseMinified(boolean minified)
protected org.springframework.core.io.Resource resolveResourceInternal(javax.servlet.http.HttpServletRequest request,
String requestPath,
List<? extends org.springframework.core.io.Resource> locations,
org.springframework.web.servlet.resource.ResourceResolverChain chain)
resolveResourceInternal in class org.springframework.web.servlet.resource.AbstractResourceResolverprotected org.springframework.core.io.Resource getResource(String requestPath, List<? extends org.springframework.core.io.Resource> locations)
protected String resolveUrlPathInternal(String resourcePath, List<? extends org.springframework.core.io.Resource> locations, org.springframework.web.servlet.resource.ResourceResolverChain chain)
resolveUrlPathInternal in class org.springframework.web.servlet.resource.AbstractResourceResolverCopyright © 2022. All rights reserved.