public class MetaDataScanner extends Reflections
DeploymentContext
that identifies nested
subdeployments (i.e. WAR inside EAR) and processes the resulting archive Url's using the Reflections library.
The initial set of config URLs (entry points) is discovered through ErraiApp.properties.Modifier and Type | Class and Description |
---|---|
static class |
MetaDataScanner.CacheHolder |
Modifier and Type | Field and Description |
---|---|
static String |
ERRAI_CONFIG_STUB_NAME |
configuration
primitiveDescriptors, primitiveNames, primitiveTypes
collect, collect, collect, collect, collect, getConverters, getFieldsAnnotatedWith, getFieldsAnnotatedWith, getMethodsAnnotatedWith, getMethodsAnnotatedWith, getMethodsWithAnyParamAnnotated, getResources, getResources, getStore, getSubTypesOf, getTypesAnnotatedWith, getTypesAnnotatedWith, getTypesAnnotatedWith, merge, save, save, scan
areAnnotationMembersMatching, areAnnotationMembersMatching, forName, forNames, getAllSuperTypes, getAllSuperTypesAnnotatedWith, getMatchingAnnotations
public static final String ERRAI_CONFIG_STUB_NAME
public static MetaDataScanner createInstance(List<URL> urls)
public static MetaDataScanner createInstance(List<URL> urls, File cacheFile)
public static void registerTypeHandler(Vfs.UrlType handler)
public Set<Class<?>> getTypesAnnotatedWithExcluding(Class<? extends Annotation> annotation, String excludeRegex)
public Set<Class<?>> getTypesAnnotatedWith(Class<? extends Annotation> annotation, Collection<String> packages)
public Set<Method> getMethodsAnnotatedWithExcluding(Class<? extends Annotation> annotation, String excludeRegex)
public Set<Method> getMethodsAnnotatedWith(Class<? extends Annotation> annotation, Collection<String> packages)
public Set<Field> getFieldsAnnotatedWith(Class<? extends Annotation> annotation, Collection<String> packages)
public Set<Class<?>> getTypesAnnotatedWith(Class<? extends Annotation> annotation)
Reflections
Inherited
is honored
Note that this (@Inherited) meta-annotation type has no effect if the annotated type is used for anything other than a class. Also, this meta-annotation causes annotations to be inherited only from superclasses; annotations on implemented interfaces have no effect.
depends on TypeAnnotationsScanner and SubTypesScanner configured, otherwise an empty set is returnedgetTypesAnnotatedWith
in class Reflections
public String getHashForTypesAnnotatedWith(String seed, Class<? extends Annotation> annotation)
public static List<URL> getConfigUrls(ClassLoader loader)
Copyright © 2013-2015 JBoss, a division of Red Hat. All Rights Reserved.