/** * Initializes the bean name defaulted */ private void initBeanNameDefaulted(EnhancedAnnotation<T> annotatedAnnotation) { if (annotatedAnnotation.isAnnotationPresent(Named.class)) { if (!"".equals(annotatedAnnotation.getAnnotation(Named.class).value())) { throw MetadataLogger.LOG.valueOnNamedStereotype(annotatedAnnotation); } beanNameDefaulted = true; } }
/** * Initializes the bean name defaulted */ private void initBeanNameDefaulted(EnhancedAnnotation<T> annotatedAnnotation) { if (annotatedAnnotation.isAnnotationPresent(Named.class)) { if (!"".equals(annotatedAnnotation.getAnnotation(Named.class).value())) { throw MetadataLogger.LOG.valueOnNamedStereotype(annotatedAnnotation); } beanNameDefaulted = true; } }
/** * Initializes the bean name defaulted */ private void initBeanNameDefaulted(EnhancedAnnotation<T> annotatedAnnotation) { if (annotatedAnnotation.isAnnotationPresent(Named.class)) { if (!"".equals(annotatedAnnotation.getAnnotation(Named.class).value())) { throw MetadataLogger.LOG.valueOnNamedStereotype(annotatedAnnotation); } beanNameDefaulted = true; } }
/** * Initializes the bean name defaulted */ private void initBeanNameDefaulted(EnhancedAnnotation<T> annotatedAnnotation) { if (annotatedAnnotation.isAnnotationPresent(Named.class)) { if (!"".equals(annotatedAnnotation.getAnnotation(Named.class).value())) { throw MetadataLogger.LOG.valueOnNamedStereotype(annotatedAnnotation); } beanNameDefaulted = true; } }
private void checkMetaAnnotations(EnhancedAnnotation<T> annotatedAnnotation) { ElementType[] elementTypes = getTargetElementTypes(annotatedAnnotation.getAnnotation(Target.class)); for (Annotation inheritedBinding : getInheritedInterceptionBindingTypes()) { ElementType[] metaAnnotationElementTypes = getTargetElementTypes(inheritedBinding.annotationType().getAnnotation(Target.class)); if (!Arrays2.containsAll(metaAnnotationElementTypes, elementTypes)) { ReflectionLogger.LOG.invalidInterceptorBindingTargetDeclaration(inheritedBinding.annotationType().getName(), Arrays.toString(metaAnnotationElementTypes), annotatedAnnotation.getJavaClass().getName(), Arrays.toString(elementTypes)); } } }
private void checkMetaAnnotations(EnhancedAnnotation<T> annotatedAnnotation) { ElementType[] elementTypes = getTargetElementTypes(annotatedAnnotation.getAnnotation(Target.class)); for (Annotation inheritedBinding : getInheritedInterceptionBindingTypes()) { ElementType[] metaAnnotationElementTypes = getTargetElementTypes(inheritedBinding.annotationType().getAnnotation(Target.class)); if (!Arrays2.containsAll(metaAnnotationElementTypes, elementTypes)) { ReflectionLogger.LOG.invalidInterceptorBindingTargetDeclaration(inheritedBinding.annotationType().getName(), Arrays.toString(metaAnnotationElementTypes), annotatedAnnotation.getJavaClass().getName(), Arrays.toString(elementTypes)); } } }
private void checkMetaAnnotations(EnhancedAnnotation<T> annotatedAnnotation) { ElementType[] elementTypes = getTargetElementTypes(annotatedAnnotation.getAnnotation(Target.class)); for (Annotation inheritedBinding : getInheritedInterceptionBindingTypes()) { ElementType[] metaAnnotationElementTypes = getTargetElementTypes(inheritedBinding.annotationType().getAnnotation(Target.class)); if (!Arrays2.containsAll(metaAnnotationElementTypes, elementTypes)) { ReflectionLogger.LOG.invalidInterceptorBindingTargetDeclaration(inheritedBinding.annotationType().getName(), Arrays.toString(metaAnnotationElementTypes), annotatedAnnotation.getJavaClass().getName(), Arrays.toString(elementTypes)); } } }
private void checkMetaAnnotations(EnhancedAnnotation<T> annotatedAnnotation) { ElementType[] elementTypes = getTargetElementTypes(annotatedAnnotation.getAnnotation(Target.class)); for (Annotation inheritedBinding : getInheritedInterceptionBindingTypes()) { ElementType[] metaAnnotationElementTypes = getTargetElementTypes(inheritedBinding.annotationType().getAnnotation(Target.class)); if (!Arrays2.containsAll(metaAnnotationElementTypes, elementTypes)) { ReflectionLogger.LOG.invalidInterceptorBindingTargetDeclaration(inheritedBinding.annotationType().getName(), Arrays.toString(metaAnnotationElementTypes), annotatedAnnotation.getJavaClass().getName(), Arrays.toString(elementTypes)); } } }
private static boolean isValidTargetType(EnhancedAnnotation<?> annotation) { Target target = annotation.getAnnotation(Target.class); return target != null && (Arrays2.unorderedEquals(target.value(), ElementType.TYPE, ElementType.METHOD) || Arrays2.unorderedEquals(target.value(), ElementType.TYPE)); }
private static boolean isValidTargetType(EnhancedAnnotation<?> annotation) { Target target = annotation.getAnnotation(Target.class); return target != null && (Arrays2.unorderedEquals(target.value(), ElementType.TYPE, ElementType.METHOD) || Arrays2.unorderedEquals(target.value(), ElementType.TYPE)); }
private static boolean isValidTargetType(EnhancedAnnotation<?> annotation) { Target target = annotation.getAnnotation(Target.class); return target != null && (Arrays2.unorderedEquals(target.value(), ElementType.TYPE, ElementType.METHOD) || Arrays2.unorderedEquals(target.value(), ElementType.TYPE)); }
private static boolean isValidTargetType(EnhancedAnnotation<?> annotation) { Target target = annotation.getAnnotation(Target.class); return target != null && (Arrays2.unorderedEquals(target.value(), ElementType.TYPE, ElementType.METHOD) || Arrays2.unorderedEquals(target.value(), ElementType.TYPE)); }
private static boolean isValidTargetType(EnhancedAnnotation<?> annotation) { Target target = annotation.getAnnotation(Target.class); return target != null && (Arrays2.unorderedEquals(target.value(), ElementType.TYPE, ElementType.METHOD) || Arrays2.unorderedEquals(target.value(), ElementType.TYPE)); }
private static boolean isValidTargetType(EnhancedAnnotation<?> annotation) { Target target = annotation.getAnnotation(Target.class); return target != null && (Arrays2.unorderedEquals(target.value(), ElementType.TYPE, ElementType.METHOD) || Arrays2.unorderedEquals(target.value(), ElementType.TYPE)); }
protected void check(EnhancedAnnotation<T> annotatedAnnotation) { if (valid && (!annotatedAnnotation.isAnnotationPresent(Retention.class) || annotatedAnnotation.isAnnotationPresent(Retention.class) && !annotatedAnnotation.getAnnotation(Retention.class).value().equals(RetentionPolicy.RUNTIME))) { this.valid = false; ReflectionLogger.LOG.missingRetention(annotatedAnnotation); } }
protected void check(EnhancedAnnotation<T> annotatedAnnotation) { if (valid && (!annotatedAnnotation.isAnnotationPresent(Retention.class) || annotatedAnnotation.isAnnotationPresent(Retention.class) && !annotatedAnnotation.getAnnotation(Retention.class).value().equals(RetentionPolicy.RUNTIME))) { this.valid = false; ReflectionLogger.LOG.missingRetention(annotatedAnnotation); } }
protected void check(EnhancedAnnotation<T> annotatedAnnotation) { if (valid && (!annotatedAnnotation.isAnnotationPresent(Retention.class) || annotatedAnnotation.isAnnotationPresent(Retention.class) && !annotatedAnnotation.getAnnotation(Retention.class).value().equals(RetentionPolicy.RUNTIME))) { this.valid = false; ReflectionLogger.LOG.missingRetention(annotatedAnnotation); } }
@Override protected void check(EnhancedAnnotation<T> annotatedAnnotation) { super.check(annotatedAnnotation); if (isValid()) { if (!annotatedAnnotation.isAnnotationPresent(Target.class)) { ReflectionLogger.LOG.missingTarget(annotatedAnnotation); } else if (!Arrays2.unorderedEquals(annotatedAnnotation.getAnnotation(Target.class).value(), METHOD, FIELD, TYPE)) { ReflectionLogger.LOG.missingTargetMethodFieldType(annotatedAnnotation); } } }
@Override protected void check(EnhancedAnnotation<T> annotatedAnnotation) { super.check(annotatedAnnotation); if (isValid()) { if (!annotatedAnnotation.isAnnotationPresent(Target.class)) { ReflectionLogger.LOG.missingTarget(annotatedAnnotation); } else if (!Arrays2.unorderedEquals(annotatedAnnotation.getAnnotation(Target.class).value(), METHOD, FIELD, TYPE)) { ReflectionLogger.LOG.missingTargetMethodFieldType(annotatedAnnotation); } } }
@Override protected void check(EnhancedAnnotation<T> annotatedAnnotation) { super.check(annotatedAnnotation); if (isValid()) { if (!annotatedAnnotation.isAnnotationPresent(Target.class)) { ReflectionLogger.LOG.missingTarget(annotatedAnnotation); } else if (!Arrays2.unorderedEquals(annotatedAnnotation.getAnnotation(Target.class).value(), METHOD, FIELD, TYPE)) { ReflectionLogger.LOG.missingTargetMethodFieldType(annotatedAnnotation); } } }