【发布时间】:2014-03-07 01:37:19
【问题描述】:
我想获取对象“obj”的子属性的类型,可以访问为
obj.property1.sub_property
此代码仅适用于像 obj.property 这样的直接属性
FacesContext.getCurrentInstance().getApplication().
getELResolver().getType(FacesContext.getCurrentInstance().getELContext(),
obj, "property1");
但是如何做到这一点
FacesContext.getCurrentInstance().getApplication().
getELResolver().getType(FacesContext.getCurrentInstance().getELContext(),
obj, "property1.sub_property");
或者如何获取完整表达式#{obj.property1.sub_property}的TYPE
【问题讨论】: