public Annotation[] getDeclaredAnnotations() { Annotation[] result = _annotations; if (result == null) { result = _ctor.getDeclaredAnnotations(); _annotations = result; } return result; }
public Annotation[] getDeclaredAnnotations() { Annotation[] result = _annotations; if (result == null) { result = _ctor.getDeclaredAnnotations(); _annotations = result; } return result; }
@Override public Annotation[] getDeclaredAnnotations() { return target.getDeclaredAnnotations(); }
@Override public Annotation[] getDeclaredAnnotations() { return target.getDeclaredAnnotations(); }
public Annotation[] getDeclaredAnnotations() { Annotation[] result = _annotations; if (result == null) { result = _ctor.getDeclaredAnnotations(); _annotations = result; } return result; }
public List<Annotation> callConstructorGetDeclaredAnnotations(Constructor<?> m) { return Arrays.asList(m.getDeclaredAnnotations()); } public boolean callConstructorIsAnnotationPresent(Constructor<?> m, Class<? extends Annotation> annotClass) {
public List<String> getMethodAnnotationNames(Member method) { Annotation[] annotations = method instanceof Method ? ((Method) method).getDeclaredAnnotations() : method instanceof Constructor ? ((Constructor) method).getDeclaredAnnotations() : null; return getAnnotationNames(annotations); }
public List<String> getMethodAnnotationNames(Member method) { Annotation[] annotations = method instanceof Method ? ((Method) method).getDeclaredAnnotations() : method instanceof Constructor ? ((Constructor) method).getDeclaredAnnotations() : null; return getAnnotationNames(annotations); }
/** * {@inheritDoc} */ @CachedReturnPlugin.Enhance("declaredAnnotations") public AnnotationList getDeclaredAnnotations() { return new AnnotationList.ForLoadedAnnotations(constructor.getDeclaredAnnotations()); }
private AnnotationMap collectAnnotations(ClassUtil.Ctor main, ClassUtil.Ctor mixin) { AnnotationCollector c = collectAnnotations(main.getConstructor().getDeclaredAnnotations()); if (mixin != null) { c = collectAnnotations(c, mixin.getConstructor().getDeclaredAnnotations()); } return c.asAnnotationMap(); }
private AnnotationMap collectAnnotations(ClassUtil.Ctor main, ClassUtil.Ctor mixin) { AnnotationCollector c = collectAnnotations(main.getConstructor().getDeclaredAnnotations()); if (mixin != null) { c = collectAnnotations(c, mixin.getConstructor().getDeclaredAnnotations()); } return c.asAnnotationMap(); }
private AnnotationMap collectAnnotations(ClassUtil.Ctor main, ClassUtil.Ctor mixin) { AnnotationCollector c = collectAnnotations(main.getConstructor().getDeclaredAnnotations()); if (mixin != null) { c = collectAnnotations(c, mixin.getConstructor().getDeclaredAnnotations()); } return c.asAnnotationMap(); }
&& !ReflectionUtils.isInject(Arrays.asList(constructor.getDeclaredAnnotations()))) { continue;
/** * @param addParamAnnotations Whether parameter annotations are to be * added as well */ protected void _addMixOvers(Constructor<?> mixin, AnnotatedConstructor target, boolean addParamAnnotations) { for (Annotation a : mixin.getDeclaredAnnotations()) { if (_annotationIntrospector.isHandled(a)) { target.addOrOverride(a); } } if (addParamAnnotations) { Annotation[][] pa = mixin.getParameterAnnotations(); for (int i = 0, len = pa.length; i < len; ++i) { for (Annotation a : pa[i]) { target.addOrOverrideParam(i, a); } } } }
return new AnnotatedConstructor(ctor, _collectRelevantAnnotations(ctor.getDeclaredAnnotations()), null); resolvedAnnotations = _collectRelevantAnnotations(paramAnns); return new AnnotatedConstructor(ctor, _collectRelevantAnnotations(ctor.getDeclaredAnnotations()), resolvedAnnotations);
private BehaviorStructure newBehaviorStructure(final Constructor constructor) { return new BehaviorStructure( new AccessImplByJDKBehavior(constructor), "<init>", this, this, newInstances(constructor.getParameterTypes()), newInstances(constructor.getExceptionTypes()), newInstances(getAnnotationTypeArray(constructor.getDeclaredAnnotations())) ); }
for (Constructor<?> constructor : clazz.getDeclaredConstructors()) { if (isPublic(constructor.getModifiers()) && !constructor.isSynthetic()) { for (Annotation annotation : constructor.getDeclaredAnnotations()) { if (annotation.annotationType().equals(BsonCreator.class)) { if (creatorExecutable != null) {
/** * @param addParamAnnotations Whether parameter annotations are to be * added as well */ protected void _addMixOvers(Constructor<?> mixin, AnnotatedConstructor target, boolean addParamAnnotations) { for (Annotation a : mixin.getDeclaredAnnotations()) { if (_annotationIntrospector.isHandled(a)) { target.addOrOverride(a); } } if (addParamAnnotations) { Annotation[][] pa = mixin.getParameterAnnotations(); for (int i = 0, len = pa.length; i < len; ++i) { for (Annotation a : pa[i]) { target.addOrOverrideParam(i, a); } } } }
return new AnnotatedConstructor(ctor, _collectRelevantAnnotations(ctor.getDeclaredAnnotations()), null); resolvedAnnotations = _collectRelevantAnnotations(paramAnns); return new AnnotatedConstructor(ctor, _collectRelevantAnnotations(ctor.getDeclaredAnnotations()), resolvedAnnotations);
@Override public <T> void visitConstructor(Constructor<T> constructor) { for (Annotation annotation : constructor.getDeclaredAnnotations()) { visitAnnotation(annotation); } int nrEnclosingClasses = getNumberOfEnclosingClasses(constructor.getDeclaringClass()); for (RtParameter parameter : RtParameter.parametersOf(constructor)) { //ignore implicit parameters of enclosing classes if (nrEnclosingClasses > 0) { nrEnclosingClasses--; continue; } visitParameter(parameter); } for (TypeVariable<Constructor<T>> aTypeParameter : constructor.getTypeParameters()) { visitTypeParameter(aTypeParameter); } for (Class<?> exceptionType : constructor.getExceptionTypes()) { visitTypeReference(CtRole.THROWN, exceptionType); } }