Implementation of the AssetResolver interface for resolving files on the classpath. It is important to note that recursive scanning does not function unless an assets.list file is supplied
Type | Name and description |
---|---|
static String |
DIRECTIVE_FILE_SEPARATOR |
static String |
NATIVE_FILE_SEPARATOR |
Collection<String> |
assetList |
String |
assetListPath |
ClassLoader |
classLoader |
String |
prefixPath |
Constructor and description |
---|
ClasspathAssetResolver
(String name, String basePath, String assetListPath = null, ClassLoader classLoader = Thread.currentThread() |
Type | Name and description |
---|---|
protected Closure<InputStream> |
createInputStreamClosure(URL file) |
AssetFile |
getAsset(String relativePath, String contentType = null, String extension = null, AssetFile baseFile = null) |
List<AssetFile> |
getAssets(String basePath, String contentType = null, String extension = null, Boolean recursive = true, AssetFile relativeFile = null, AssetFile baseFile = null) |
protected String |
getFileName(URL url) |
URL |
getRelativeFile(String relativePath, String name) |
String |
relativePathToResolver(URL file, String scanDirectoryPath) |
Collection<AssetFile> |
scanForFiles(List<String> excludePatterns, List<String> includePatterns) Uses file globbing to scan for files that need precompiled |
Methods inherited from class | Name |
---|---|
class AbstractAssetResolver |
assetForFile, convertGlobToRegEx, createInputStreamClosure, getFileName, getRelativeFile, isFileMatchingPatterns, relativePathToResolver, resolveAsset |
Uses file globbing to scan for files that need precompiled
Groovy Documentation