Refine search
public static <X> BackedAnnotatedType<X> of(Class<X> javaClass, Type baseType, SharedObjectCache sharedObjectCache, ReflectionCache reflectionCache, String contextId, String bdaId, String suffix) { return new BackedAnnotatedType<X>(javaClass, baseType, sharedObjectCache, reflectionCache, contextId, bdaId, suffix); }
public boolean isAnnotationPresent(Class<? extends Annotation> annotationType) { return getAnnotation(annotationType) != null; }
public <T extends Annotation> T getAnnotation(Class<T> annotationType) { for (Annotation annotation : getAnnotations()) { if (annotation.annotationType().equals(annotationType)) { return annotationType.cast(annotation); } } return null; }
public <T> void disposeBackedAnnotatedType(Class<T> rawType, String bdaId, String suffix) { TypeHolder<T> typeHolder = new TypeHolder<>(rawType, rawType, bdaId, suffix); BackedAnnotatedType<T> annotatedType = cast(this.backedAnnotatedTypes.getValueIfPresent(typeHolder)); if (annotatedType != null) { this.backedAnnotatedTypes.invalidate(typeHolder); this.slimAnnotatedTypesById.remove(annotatedType.getIdentifier()); this.enhancedAnnotatedTypes.invalidate(annotatedType); } }
@Override protected Iterable<AnnotatedMethod<X>> getCandidates() { return cast(type.getMethods()); } }
if (containsAnnotation(annotatedType.getAnnotations(), requiredAnnotation, true)) { return true; for (Class<?> clazz = annotatedType.getJavaClass(); clazz != null && clazz != Object.class; clazz = clazz.getSuperclass()) { for (Class<?> interfaceClazz : Reflections.getInterfaceClosure(annotatedType.getJavaClass())) { for (Method method : interfaceClazz.getDeclaredMethods()) { if (Reflections.isDefault(method)) { if (containsAnnotations(cache.getAnnotations(method), requiredAnnotation)) { return true;
@Override public BackedAnnotatedType<?> apply(TypeHolder<?> typeHolder) { // make sure declaring class (if any) is loadable before loading this class Reflections.checkDeclaringClassLoadable(typeHolder.getRawType()); BackedAnnotatedType<?> type = BackedAnnotatedType.of(typeHolder.getRawType(), typeHolder.getBaseType(), cache, reflectionCache, contextId, typeHolder.getBdaId(), typeHolder.getSuffix()); return updateLookupTable(type); } }
public static <X> BackedAnnotatedType<X> of(Class<X> javaClass, Type baseType, SharedObjectCache sharedObjectCache, ReflectionCache reflectionCache, String contextId, String bdaId) { return of(javaClass, baseType, sharedObjectCache, reflectionCache, contextId, bdaId, null); }
@Override protected ReflectionCache getReflectionCache() { return getDeclaringType().getReflectionCache(); }
int nesting = Reflections.getNesting(getDeclaringType().getJavaClass()); for (int i = 0; i < parameterTypes.length; i++) { int gi = i - nesting;
if (containsAnnotations(annotatedType.getAnnotations(), requiredAnnotation, true)) { return true; for (Class<?> clazz = annotatedType.getJavaClass(); clazz != null && clazz != Object.class; clazz = clazz.getSuperclass()) {
@Override protected Iterable<AnnotatedConstructor<X>> getCandidates() { return type.getConstructors(); } }
private Object writeReplace() throws ObjectStreamException { return new SerializationProxy<X>(getIdentifier()); }
public <T> void disposeBackedAnnotatedType(Class<T> rawType, String bdaId, String suffix) { TypeHolder<T> typeHolder = new TypeHolder<>(rawType, rawType, bdaId, suffix); BackedAnnotatedType<T> annotatedType = cast(this.backedAnnotatedTypes.getValueIfPresent(typeHolder)); if (annotatedType != null) { this.backedAnnotatedTypes.invalidate(typeHolder); this.slimAnnotatedTypesById.remove(annotatedType.getIdentifier()); this.enhancedAnnotatedTypes.invalidate(annotatedType); } }
@Override protected Iterable<AnnotatedMethod<X>> getCandidates() { return cast(type.getMethods()); } }
if (containsAnnotation(annotatedType.getAnnotations(), requiredAnnotation, true)) { return true; for (Class<?> clazz = annotatedType.getJavaClass(); clazz != null && clazz != Object.class; clazz = clazz.getSuperclass()) { for (Class<?> interfaceClazz : Reflections.getInterfaceClosure(annotatedType.getJavaClass())) { for (Method method : interfaceClazz.getDeclaredMethods()) { if (Reflections.isDefault(method)) { if (containsAnnotations(cache.getAnnotations(method), requiredAnnotation)) { return true;
@Override public BackedAnnotatedType<?> apply(TypeHolder<?> typeHolder) { // make sure declaring class (if any) is loadable before loading this class Reflections.checkDeclaringClassLoadable(typeHolder.getRawType()); BackedAnnotatedType<?> type = BackedAnnotatedType.of(typeHolder.getRawType(), typeHolder.getBaseType(), cache, reflectionCache, contextId, typeHolder.getBdaId(), typeHolder.getSuffix()); return updateLookupTable(type); } }
public static <X> BackedAnnotatedType<X> of(Class<X> javaClass, SharedObjectCache sharedObjectCache, ReflectionCache reflectionCache, String contextId, String bdaId) { return of(javaClass, javaClass, sharedObjectCache, reflectionCache, contextId, bdaId); }