@Override public Object getValue(RuntimeContext runtimeContext) throws IOException { return ContextHelper.getReference(referenceName, (Class<?>)getGenericType(), runtimeContext.getAttribute(ServletContext.class)); }
@Override public Object getValue(RuntimeContext runtimeContext) throws IOException { return ContextHelper.getReference(referenceName, (Class<?>)getGenericType(), runtimeContext.getAttribute(ServletContext.class)); }
boolean allowFindByType) { Object bean = ContextHelper.getReference(name, type, ctx); if (bean == null) { throw new StripesRuntimeException("no reference defined:" + name);
Reference ref = field.getAnnotation(Reference.class); String name = ref.name() != null && !ref.name().equals("") ? ref.name() : field.getName(); Object value = getReference(name, field.getType(), sc); setField(instance, field, value); } else if (field.isAnnotationPresent(Property.class)) { Reference ref = method.getAnnotation(Reference.class); String name = ref.name() != null && !ref.name().equals("") ? ref.name() : targetName; Object value = getReference(name, type, sc); setMethod(instance, method, value); } else if (method.isAnnotationPresent(Property.class)) {
Reference ref = field.getAnnotation(Reference.class); String name = ref.name() != null && !ref.name().equals("") ? ref.name() : field.getName(); Object value = getReference(name, field.getType(), sc); setField(instance, field, value); } else if (field.isAnnotationPresent(Property.class)) { Reference ref = method.getAnnotation(Reference.class); String name = ref.name() != null && !ref.name().equals("") ? ref.name() : targetName; Object value = getReference(name, type, sc); setMethod(instance, method, value); } else if (method.isAnnotationPresent(Property.class)) {