|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.mmm.util.reflect.base.ResourceNameCollector
public class ResourceNameCollector
This is an implementation of the ResourceVisitor interface that
collects the names of all resources accepted by
a given filter in a Set.
| Field Summary | |
|---|---|
private Filter<String> |
filter
Filter to accept resource-names. |
private Set<String> |
resourceSet
Set to collect resource-names. |
| Constructor Summary | |
|---|---|
ResourceNameCollector(Set<String> resourceSet,
Filter<String> filter)
The constructor. |
|
| Method Summary | |
|---|---|
boolean |
visitPackage(String classpath)
This method is invoked for each traversed package. |
void |
visitResource(String classpath)
This method is invoked for each resource. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private final Set<String> resourceSet
Set to collect resource-names.
private final Filter<String> filter
Filter to accept resource-names.
| Constructor Detail |
|---|
public ResourceNameCollector(Set<String> resourceSet,
Filter<String> filter)
resourceSet - is the Set where collected resource-names will
be added.filter - is used to filter resources by
name.| Method Detail |
|---|
public boolean visitPackage(String classpath)
visitPackage in interface ResourceVisitorclasspath - is the absolute classpath of the traversed package (e.g.
"net/sf/mmm/util/reflect").
true if the package should be traversed recursively,
false if the package and all its content (including
sub-packages) should be skipped.public void visitResource(String classpath)
visitResource in interface ResourceVisitorclasspath - is the absolute classpath of the resource (e.g.
"net/sf/mmm/util/reflect/api/ReflectionUtil.class" or
"net/sf/mmm/util/reflect/beans-reflect.xml").
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||