Package org.alfresco.util
Class BaseApplicationContextHelper.ResourceFinder
- java.lang.Object
-
- org.springframework.core.io.support.PathMatchingResourcePatternResolver
-
- org.springframework.web.context.support.ServletContextResourcePatternResolver
-
- org.alfresco.util.BaseApplicationContextHelper.ResourceFinder
-
- All Implemented Interfaces:
org.springframework.core.io.ResourceLoader
,org.springframework.core.io.support.ResourcePatternResolver
- Enclosing class:
- BaseApplicationContextHelper
public static class BaseApplicationContextHelper.ResourceFinder extends org.springframework.web.context.support.ServletContextResourcePatternResolver
Can be used in Spring configuration to search for all resources matching an array of patterns.- Author:
- dward
-
-
Constructor Summary
Constructors Constructor Description ResourceFinder()
ResourceFinder(org.springframework.core.io.ResourceLoader resourceLoader)
The Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.core.io.Resource[]
getResources(java.lang.String... locationPatterns)
Gets an array of resources matching the given location patterns.-
Methods inherited from class org.springframework.web.context.support.ServletContextResourcePatternResolver
doFindPathMatchingFileResources, doRetrieveMatchingServletContextResources
-
Methods inherited from class org.springframework.core.io.support.PathMatchingResourcePatternResolver
addAllClassLoaderJarRoots, addClassPathManifestEntries, convertClassLoaderURL, determineRootDir, doFindAllClassPathResources, doFindMatchingFileSystemResources, doFindPathMatchingJarResources, doRetrieveMatchingFiles, findAllClassPathResources, findPathMatchingResources, getClassLoader, getJarFile, getPathMatcher, getResource, getResourceLoader, getResources, isJarResource, listDirectory, resolveRootDirResource, retrieveMatchingFiles, setPathMatcher
-
-
-
-
Method Detail
-
getResources
public org.springframework.core.io.Resource[] getResources(java.lang.String... locationPatterns) throws java.io.IOException
Gets an array of resources matching the given location patterns.- Parameters:
locationPatterns
- the location patterns- Returns:
- the matching resources, ordered by locationPattern index and location in the classpath
- Throws:
java.io.IOException
- Signals that an I/O exception has occurred.
-
-