|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface PackageScanClassResolver
A resolver that can find resources based on package scanning.
Method Summary | |
---|---|
void |
addClassLoader(ClassLoader classLoader)
Adds the class loader to the existing loaders |
void |
addFilter(PackageScanFilter filter)
Add a filter that will be applied to all scan operations |
Set<Class<?>> |
findAnnotated(Class<? extends Annotation> annotation,
String... packageNames)
Attempts to discover classes that are annotated with to the annotation. |
Set<Class<?>> |
findAnnotated(Set<Class<? extends Annotation>> annotations,
String... packageNames)
Attempts to discover classes that are annotated with to the annotation. |
Set<Class<?>> |
findByFilter(PackageScanFilter filter,
String... packageNames)
Attempts to discover classes filter by the provided filter |
Set<Class<?>> |
findImplementations(Class<?> parent,
String... packageNames)
Attempts to discover classes that are assignable to the type provided. |
Set<ClassLoader> |
getClassLoaders()
Gets the ClassLoader instances that should be used when scanning for classes. |
void |
removeFilter(PackageScanFilter filter)
Removes the filter |
void |
setClassLoaders(Set<ClassLoader> classLoaders)
Deprecated. use addClassLoader(ClassLoader) instead. |
Method Detail |
---|
@Deprecated void setClassLoaders(Set<ClassLoader> classLoaders)
addClassLoader(ClassLoader)
instead.
classLoaders
- loaders to use when scanning for classesSet<ClassLoader> getClassLoaders()
addClassLoader(ClassLoader)
method if you want to add new classloaders
to the class loaders list.
void addClassLoader(ClassLoader classLoader)
classLoader
- the loader to addSet<Class<?>> findAnnotated(Class<? extends Annotation> annotation, String... packageNames)
annotation
- the annotation that should be present on matching classespackageNames
- one or more package names to scan (including subpackages) for classes
Set<Class<?>> findAnnotated(Set<Class<? extends Annotation>> annotations, String... packageNames)
annotations
- the annotations that should be present (any of them) on matching classespackageNames
- one or more package names to scan (including subpackages) for classes
Set<Class<?>> findImplementations(Class<?> parent, String... packageNames)
parent
- the class of interface to find subclasses or implementations ofpackageNames
- one or more package names to scan (including subpackages) for classes
Set<Class<?>> findByFilter(PackageScanFilter filter, String... packageNames)
filter
- filter to filter desired classes.packageNames
- one or more package names to scan (including subpackages) for classes
void addFilter(PackageScanFilter filter)
filter
- filter to filter desired classes in all scan operationsvoid removeFilter(PackageScanFilter filter)
filter
- filter to filter desired classes in all scan operations
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |