[
https://issues.jboss.org/browse/JBEE-159?page=com.atlassian.jira.plugin.s...
]
Rich DiCroce commented on JBEE-159:
-----------------------------------
Still a problem on WildFly 12.0.0.Final (EL API 1.0.11.Final)
PropertyNotFoundException when the property is a JDK8 defender
method
---------------------------------------------------------------------
Key: JBEE-159
URL:
https://issues.jboss.org/browse/JBEE-159
Project: JBoss JavaEE Spec APIs
Issue Type: Enhancement
Components: jboss-el-api
Affects Versions: jboss-el-api_3.0_spec-1.0.2.Final
Reporter: Rich DiCroce
Assignee: Scott Marlow
Priority: Minor
Labels: java8
I have a class that implements an interface that uses Java 8's new defender methods
feature. Some getters on the interface have default implementations, and the concrete
classes don't override them.
If I try to refer to one of these getters as a property like so:
{code:xml}
value="#{cc.filter.filter.valueChoices}"
{code}
Then I get this exception:
{noformat}
Caused by: javax.el.PropertyNotFoundException: The class
'com.lapis.jsf.framework.dao.search.DefaultEntityFilter' does not have the
property 'valueChoices'.
at javax.el.BeanELResolver.getBeanProperty(BeanELResolver.java:731)
[jboss-el-api_3.0_spec-1.0.3.Final.jar:1.0.3.Final]
at javax.el.BeanELResolver.getValue(BeanELResolver.java:351)
[jboss-el-api_3.0_spec-1.0.3.Final.jar:1.0.3.Final]
at
com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:176)
[jsf-impl-2.2.6-jbossorg-4.jar:]
at com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:203)
[jsf-impl-2.2.6-jbossorg-4.jar:]
at com.sun.el.parser.AstValue.getValue(AstValue.java:140) [javax.el-3.0.0.jar:]
at com.sun.el.parser.AstValue.getValue(AstValue.java:204) [javax.el-3.0.0.jar:]
at com.sun.el.parser.AstEmpty.getValue(AstEmpty.java:66) [javax.el-3.0.0.jar:]
at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:226)
[javax.el-3.0.0.jar:]
at org.jboss.weld.el.WeldValueExpression.getValue(WeldValueExpression.java:50)
[weld-core-impl-2.1.2.Final.jar:2014-01-09 09:23]
at org.jboss.weld.el.WeldValueExpression.getValue(WeldValueExpression.java:50)
[weld-core-impl-2.1.2.Final.jar:2014-01-09 09:23]
at
com.sun.faces.facelets.el.ContextualCompositeValueExpression.getValue(ContextualCompositeValueExpression.java:158)
[jsf-impl-2.2.6-jbossorg-4.jar:]
at com.sun.faces.facelets.el.TagValueExpression.getValue(TagValueExpression.java:109)
[jsf-impl-2.2.6-jbossorg-4.jar:]
... 68 more
{noformat}
Two workarounds exist. One: you can override the default method in a concrete class and
have it just call the default super method. Two: you can call the getter using a method
expression instead of a value expression.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)