int i = beanPath.indexOf(".");
String beanName = i<0?beanPath:beanPath.substring(0,i);
Object namedBean = appCtx.getBean(beanName);
BeanWrapperImpl bwrap = new BeanWrapperImpl(namedBean);
String propPath = beanPath.substring(i+1);
Object coercedVal = bwrap.convertIfNecessary(newVal, bwrap.getPropertyValue(propPath).getClass());
bwrap.setPropertyValue(propPath, coercedVal);
}
Reference ref = getRequest().getResourceRef();
ref.setPath(getBeansRefPath());
ref.addSegment(beanPath);