public abstract class ClassQueryTool extends Object
Modifier | Constructor and Description |
---|---|
protected |
ClassQueryTool()
The default constructor.
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
isValidClass(String className)
Checks, whether the class is valid.
|
protected abstract void |
processClass(ClassLoader classLoader,
Class c)
The handler method that is called for every class encountered on the classpath.
|
void |
processDirectory(File directory)
Processes all entries from a given directory, ignoring any subdirectory contents.
|
protected void |
processEntry(ClassLoader classLoader,
String entryName)
Processes a single class-file entry.
|
protected void processEntry(ClassLoader classLoader, String entryName)
classLoader
- the classloader that should be used for class- and resource loading.entryName
- the file name in the classpath.protected boolean isValidClass(String className)
className
- the name of the class.protected abstract void processClass(ClassLoader classLoader, Class c)
classLoader
- the classloader used to load the class.c
- the class that should be handled.public void processDirectory(File directory) throws IOException
directory
- the directory to be searched, or null to just use the classpath.IOException
- if an error occured while loading the resources from the directory.SecurityException
- if access to the system properties or access to the classloader is restricted.Copyright © 2017 Hitachi Vantara. All rights reserved.