Package org.jboss.modules
Interface IterableResourceLoader
-
- All Superinterfaces:
java.lang.AutoCloseable
,ResourceLoader
public interface IterableResourceLoader extends ResourceLoader
A resource loader which has the ability to enumerate its contents.- Author:
- David M. Lloyd
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Iterator<Resource>
iterateResources(java.lang.String startPath, boolean recursive)
Enumerate all the resources under the given path.-
Methods inherited from interface org.jboss.modules.ResourceLoader
close, createSubloader, getClassSpec, getLibrary, getLocation, getPackageSpec, getPaths, getResource, getRootName
-
-
-
-
Method Detail
-
iterateResources
java.util.Iterator<Resource> iterateResources(java.lang.String startPath, boolean recursive)
Enumerate all the resources under the given path. The given path name is relative to the root of the resource loader. If the path "escapes" the root via..
, such segments will be consumed. If the path is absolute, it will be converted to a relative path by dropping the leading/
.- Parameters:
startPath
- the path to search underrecursive
-true
to recursively descend into subdirectories,false
to only read this path- Returns:
- the resource iterator (possibly empty)
-
-