public ThreadLocalProxy<?> getContextFieldProxy(Field f) { return getProxy(getFieldProxyMap(true), f); }
public ThreadLocalProxy<?> getContextFieldProxy(Field f) { return getProxy(getFieldProxyMap(), f); }
private void findContextFields(Class<?> cls, Object provider) { if (cls == Object.class || cls == null) { return; } for (Field f : cls.getDeclaredFields()) { for (Annotation a : f.getAnnotations()) { if (a.annotationType() == Context.class && (f.getType().isInterface() || f.getType() == Application.class)) { contextFields = addContextField(contextFields, f); checkContextClass(f.getType()); if (!InjectionUtils.VALUE_CONTEXTS.contains(f.getType().getName())) { addToMap(getFieldProxyMap(true), f, getFieldThreadLocalProxy(f, provider)); } } } } findContextFields(cls.getSuperclass(), provider); }
private void findContextFields(Class<?> cls, Object provider) { if (cls == Object.class || cls == null) { return; } for (Field f : cls.getDeclaredFields()) { for (Annotation a : f.getAnnotations()) { if (a.annotationType() == Context.class || a.annotationType() == Resource.class && AnnotationUtils.isContextClass(f.getType())) { contextFields = addContextField(contextFields, f); if (f.getType() != Application.class) { addToMap(getFieldProxyMap(), f, getFieldThreadLocalProxy(f, provider)); } } } } findContextFields(cls.getSuperclass(), provider); }
public void clearThreadLocalProxies() { clearProxies(getFieldProxyMap()); clearProxies(getSetterProxyMap()); }
public void clearThreadLocalProxies() { clearProxies(getFieldProxyMap(false)); clearProxies(getSetterProxyMap(false)); clearProxies(getConstructorProxyMap(false)); }