private boolean containsBeanDefiningAnnotation(ClassInfo cinfo, String className) { for (Entry<DotName, List<AnnotationInstance>> entry : cinfo.annotations().entrySet()) { if (beanDefiningAnnotations.contains(entry.getKey())) { return true; } if (isDeclaredOnBeanClass(entry, cinfo) && cindex.getClassByName(entry.getKey()) == null) { // Annotation not found in the composite index - falling back to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz != null) { for (Class<? extends Annotation> metaAnnotation : Reflections.META_ANNOTATIONS) { if (hasBeanDefiningMetaAnnotationSpecified(clazz.getAnnotations(), metaAnnotation)) { return true; } } } } } return false; }
private boolean containsBeanDefiningAnnotation(ClassInfo cinfo, String className) { for (Entry<DotName, List<AnnotationInstance>> entry : cinfo.annotations().entrySet()) { if (beanDefiningAnnotations.contains(entry.getKey())) { return true; } if (isDeclaredOnBeanClass(entry, cinfo) && cindex.getClassByName(entry.getKey()) == null) { // Annotation not found in the composite index - falling back to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz != null) { for (Class<? extends Annotation> metaAnnotation : Reflections.META_ANNOTATIONS) { if (hasBeanDefiningMetaAnnotationSpecified(clazz.getAnnotations(), metaAnnotation)) { return true; } } } } } return false; }
private boolean containsBeanDefiningAnnotation(ClassInfo cinfo, String className) { for (Entry<DotName, List<AnnotationInstance>> entry : cinfo.annotations().entrySet()) { if (beanDefiningAnnotations.contains(entry.getKey())) { return true; } if (isDeclaredOnBeanClass(entry, cinfo) && cindex.getClassByName(entry.getKey()) == null) { // Annotation not found in the composite index - falling back to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz != null) { for (Class<? extends Annotation> metaAnnotation : Reflections.META_ANNOTATIONS) { if (hasBeanDefiningMetaAnnotationSpecified(clazz.getAnnotations(), metaAnnotation)) { return true; } } } } } return false; }
private boolean containsBeanDefiningAnnotation(ClassInfo cinfo, String className) { for (Entry<DotName, List<AnnotationInstance>> entry : cinfo.annotations().entrySet()) { if (beanDefiningAnnotations.contains(entry.getKey())) { return true; } if (isDeclaredOnBeanClass(entry, cinfo) && cindex.getClassByName(entry.getKey()) == null) { // Annotation not found in the composite index - falling back to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz != null) { for (Class<? extends Annotation> metaAnnotation : Reflections.META_ANNOTATIONS) { if (hasBeanDefiningMetaAnnotationSpecified(clazz.getAnnotations(), metaAnnotation)) { return true; } } } } } return false; }
private boolean containsBeanDefiningAnnotation(ClassInfo cinfo, String className) { for (Entry<DotName, List<AnnotationInstance>> entry : cinfo.annotations().entrySet()) { if (beanDefiningAnnotations.contains(entry.getKey())) { return true; } if (isDeclaredOnBeanClass(entry, cinfo) && cindex.getClassByName(entry.getKey()) == null) { // Annotation not found in the composite index - falling back to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz != null) { for (Class<? extends Annotation> metaAnnotation : Reflections.META_ANNOTATIONS) { if (hasBeanDefiningMetaAnnotationSpecified(clazz.getAnnotations(), metaAnnotation)) { return true; } } } } } return false; }
private boolean containsBeanDefiningAnnotation(ClassInfo cinfo, String className) { for (Entry<DotName, List<AnnotationInstance>> entry : cinfo.annotations().entrySet()) { if (beanDefiningAnnotations.contains(entry.getKey())) { return true; } if (isDeclaredOnBeanClass(entry, cinfo) && cindex.getClassByName(entry.getKey()) == null) { // Annotation not found in the composite index - falling back to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz != null) { for (Class<? extends Annotation> metaAnnotation : Reflections.META_ANNOTATIONS) { if (hasBeanDefiningMetaAnnotationSpecified(clazz.getAnnotations(), metaAnnotation)) { return true; } } } } } return false; }
private boolean containsBeanDefiningAnnotation(ClassInfo cinfo, String className) { for (Entry<DotName, List<AnnotationInstance>> entry : cinfo.annotations().entrySet()) { if (beanDefiningAnnotations.contains(entry.getKey())) { return true; } if (isDeclaredOnBeanClass(entry, cinfo) && cindex.getClassByName(entry.getKey()) == null) { // Annotation not found in the composite index - falling back to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz != null) { for (Class<? extends Annotation> metaAnnotation : Reflections.META_ANNOTATIONS) { if (hasBeanDefiningMetaAnnotationSpecified(clazz.getAnnotations(), metaAnnotation)) { return true; } } } } } return false; }
@Override protected WeldBeanDeploymentArchive processAnnotatedDiscovery(BeanArchiveBuilder builder) { Iterator<String> classIterator = builder.getClassIterator(); while (classIterator.hasNext()) { String className = classIterator.next(); ClassInfo cinfo = cindex.getClassByName(DotName.createSimple(className)); if (cinfo != null) { if (!containsBeanDefiningAnnotation(cinfo, className)) { classIterator.remove(); } } else { //if ClassInfo is not available (e.g for WEB-INF/lib/jars) then fallback to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz == null || !Reflections.hasBeanDefiningAnnotation(clazz, initialBeanDefiningAnnotations)) { classIterator.remove(); } } } return builder.build(); }
@Override protected WeldBeanDeploymentArchive processAnnotatedDiscovery(BeanArchiveBuilder builder) { Iterator<String> classIterator = builder.getClassIterator(); while (classIterator.hasNext()) { String className = classIterator.next(); ClassInfo cinfo = cindex.getClassByName(DotName.createSimple(className)); if (cinfo != null) { if (!containsBeanDefiningAnnotation(cinfo, className)) { classIterator.remove(); } } else { //if ClassInfo is not available (e.g for WEB-INF/lib/jars) then fallback to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz == null || !Reflections.hasBeanDefiningAnnotation(clazz, initialBeanDefiningAnnotations)) { classIterator.remove(); } } } return builder.build(); }
@Override protected WeldBeanDeploymentArchive processAnnotatedDiscovery(BeanArchiveBuilder builder) { Iterator<String> classIterator = builder.getClassIterator(); while (classIterator.hasNext()) { String className = classIterator.next(); ClassInfo cinfo = cindex.getClassByName(DotName.createSimple(className)); if (cinfo != null) { if (!containsBeanDefiningAnnotation(cinfo, className)) { classIterator.remove(); } } else { //if ClassInfo is not available (e.g for WEB-INF/lib/jars) then fallback to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz == null || !Reflections.hasBeanDefiningAnnotation(clazz, initialBeanDefiningAnnotations)) { classIterator.remove(); } } } return builder.build(); }
@Override protected WeldBeanDeploymentArchive processAnnotatedDiscovery(BeanArchiveBuilder builder) { Iterator<String> classIterator = builder.getClassIterator(); while (classIterator.hasNext()) { String className = classIterator.next(); ClassInfo cinfo = cindex.getClassByName(DotName.createSimple(className)); if (cinfo != null) { if (!containsBeanDefiningAnnotation(cinfo, className)) { classIterator.remove(); } } else { //if ClassInfo is not available (e.g for WEB-INF/lib/jars) then fallback to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz == null || !Reflections.hasBeanDefiningAnnotation(clazz, initialBeanDefiningAnnotations)) { classIterator.remove(); } } } return builder.build(); }
@Override protected WeldBeanDeploymentArchive processAnnotatedDiscovery(BeanArchiveBuilder builder) { Iterator<String> classIterator = builder.getClassIterator(); while (classIterator.hasNext()) { String className = classIterator.next(); ClassInfo cinfo = cindex.getClassByName(DotName.createSimple(className)); if (cinfo != null) { if (!containsBeanDefiningAnnotation(cinfo, className)) { classIterator.remove(); } } else { //if ClassInfo is not available (e.g for WEB-INF/lib/jars) then fallback to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz == null || !Reflections.hasBeanDefiningAnnotation(clazz, initialBeanDefiningAnnotations)) { classIterator.remove(); } } } return builder.build(); }
@Override protected WeldBeanDeploymentArchive processAnnotatedDiscovery(BeanArchiveBuilder builder) { Iterator<String> classIterator = builder.getClassIterator(); while (classIterator.hasNext()) { String className = classIterator.next(); ClassInfo cinfo = cindex.getClassByName(DotName.createSimple(className)); if (cinfo != null) { if (!containsBeanDefiningAnnotation(cinfo, className)) { classIterator.remove(); } } else { //if ClassInfo is not available (e.g for WEB-INF/lib/jars) then fallback to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz == null || !Reflections.hasBeanDefiningAnnotation(clazz, initialBeanDefiningAnnotations)) { classIterator.remove(); } } } return builder.build(); }
@Override protected WeldBeanDeploymentArchive processAnnotatedDiscovery(BeanArchiveBuilder builder) { Iterator<String> classIterator = builder.getClassIterator(); while (classIterator.hasNext()) { String className = classIterator.next(); ClassInfo cinfo = cindex.getClassByName(DotName.createSimple(className)); if (cinfo != null) { if (!containsBeanDefiningAnnotation(cinfo, className)) { classIterator.remove(); } } else { //if ClassInfo is not available (e.g for WEB-INF/lib/jars) then fallback to reflection Class<?> clazz = Reflections.loadClass(resourceLoader, className); if (clazz == null || !Reflections.hasBeanDefiningAnnotation(clazz, initialBeanDefiningAnnotations)) { classIterator.remove(); } } } return builder.build(); }