public class ResourceScanner extends Object
Constructor and Description |
---|
ResourceScanner(URL[] locations,
String relPath)
Creates an instance of this class with the given locations.
|
Modifier and Type | Method and Description |
---|---|
String |
getRelativePath(URL resourceURL)
Returns the relative path of the given resource url
|
URL |
getResource(String relPath)
Gets the resource with the given relative path.
|
URL[] |
getResourcesByPattern(String patternString)
Retrieves all resource matching the given pattern.
|
void |
scan(com.bc.ceres.core.ProgressMonitor pm)
Scans recursivley for resources in the location given by the constructor.
|
public void scan(com.bc.ceres.core.ProgressMonitor pm)
public URL getResource(String relPath)
relPath
- the relative path to the resource.null
if no resource was found.public String getRelativePath(URL resourceURL)
resourceURL
- null
public URL[] getResourcesByPattern(String patternString)
Pattern
.patternString
- the pattern given as a regular expressionnull
.Copyright © 2002–2014 Brockmann Consult GmbH. All rights reserved.