Class ResourceWalker
java.lang.Object
clazzfish.core.ResourceWalker
his class scans a sub directory for a given suffix. It is a re-implentation
of the ResourceWalker in the monitor package but without dependencies to
commons-io.
- Since:
- 3.0 (26.09.25)
- Author:
- oboehm
-
Constructor Summary
ConstructorsConstructorDescriptionResourceWalker(File dir) Instantiates a new Resource walker for all resources.ResourceWalker(File dir, String suffix) Instantiates a new resource walker for resources with the given suffix. -
Method Summary
Modifier and TypeMethodDescriptionWalk thru the directories and return all class files as classname, e.g. a file java/lang/String.class is returned as "java.lang.String".Walk thru the directories and return all found file resources.
-
Constructor Details
-
ResourceWalker
Instantiates a new Resource walker for all resources.- Parameters:
dir- the start dir
-
ResourceWalker
-
-
Method Details
-
getResources
Walk thru the directories and return all found file resources.- Returns:
- a collection of resources
- Throws:
IOException- Signals that an I/O exception has occurred.
-
getClasses
Walk thru the directories and return all class files as classname, e.g. a file java/lang/String.class is returned as "java.lang.String".- Returns:
- a collection of classnames
- Throws:
IOException- Signals that an I/O exception has occurred.
-