Package io.jmix.core
Interface Resources
- All Superinterfaces:
- org.springframework.core.io.ResourceLoader
- All Known Implementing Classes:
- ResourcesImpl
public interface Resources
extends org.springframework.core.io.ResourceLoader
Central infrastructure interface for loading resources.
 Searches for a resource according to the following rules:
 
- If the given location represents an URL, searches for this URL.
-  If the given location starts from classpath:prefix, searches for a classpath resource.
-  If not an URL, try to find a file below the confdirectory using the given location as relative path. If a file found, uses this file.
- Otherwise searches for a classpath resource for the given location.
- 
Field SummaryFields inherited from interface org.springframework.core.io.ResourceLoaderCLASSPATH_URL_PREFIX
- 
Method SummaryModifier and TypeMethodDescriptiongetResourceAsStream(String location) Searches for a resource according to the rules explained inResourcesand returns the resource as stream if found.getResourceAsString(String location) Searches for a resource according to the rules explained inResourcesand returns the resource as string if found.Methods inherited from interface org.springframework.core.io.ResourceLoadergetClassLoader, getResource
- 
Method Details- 
getResourceAsStreamSearches for a resource according to the rules explained inResourcesand returns the resource as stream if found. The returned stream should be closed after use.- Parameters:
- location- resource location
- Returns:
- InputStream or null if the resource is not found
 
- 
getResourceAsStringSearches for a resource according to the rules explained inResourcesand returns the resource as string if found.- Parameters:
- location- resource location
- Returns:
- resource content or null if the resource is not found
 
 
-