Klasse PackageResources
java.lang.Object
org.apache.torque.generator.configuration.PackageResources
A Container of resources which contain a specific package.
- Version:
- $Id: $
-
Konstruktorübersicht
KonstruktorenKonstruktorBeschreibungPackageResources
(String packageToFind, ClassLoader classLoader) Constructor, finds the resources for a certain package. -
Methodenübersicht
Modifizierer und TypMethodeBeschreibunggetAllResourcesEndingWith
(String suffix, boolean recurse) Returns all resource names in the package ending with the defined suffix.Returns all directories containing the desired package.Returns all jar files containing the desired package.boolean
isEmpty()
Returns whether the queried package exists in the class path.
-
Konstruktordetails
-
PackageResources
public PackageResources(String packageToFind, ClassLoader classLoader) throws ConfigurationException Constructor, finds the resources for a certain package.- Parameter:
packageToFind
- the path to the package, using / or \\ as path separator.classLoader
- the class loader to use.- Löst aus:
ConfigurationException
- when accessing the class path fails.
-
-
Methodendetails
-
getJarFiles
Returns all jar files containing the desired package.- Gibt zurück:
- the jar files, not null.
-
getDirectories
Returns all directories containing the desired package.- Gibt zurück:
- the directories, not null.
-
isEmpty
public boolean isEmpty()Returns whether the queried package exists in the class path.- Gibt zurück:
- true if package does not exist
-
getAllResourcesEndingWith
Returns all resource names in the package ending with the defined suffix.- Parameter:
suffix
- the suffix which the resource name must have, or null to match every file name.recurse
- true if subpackages should also be searched, false if only the specified package should be searched.- Gibt zurück:
- A collection of resource names with the specified suffix, not null. The contained file names are relative to the scanned package.
-