简体   繁体   English

扩展复选框相关的jsf组件时出现“无法解析类型javax.el.ValueExpression”错误

[英]"The type javax.el.ValueExpression cannot be resolved" error when extending checkbox related jsf components

I am creating JSF2 custom components and eclipse shows following error at the first line of the class.我正在创建 JSF2 自定义组件,eclipse 在类的第一行显示以下错误。

The type javax.el.ValueExpression cannot be resolved. It is indirectly referenced from required .class files

Error only shown when my component extends checkbox related components like HtmlSelectBooleanCheckbox or HtmlSelectManyCheckbox .仅当我的组件扩展复选框相关组件(如HtmlSelectBooleanCheckboxHtmlSelectManyCheckbox时才会显示错误。 Other components like HtmlSelectOneMenu , HtmlInputText are ok.其他组件如HtmlSelectOneMenuHtmlInputText都可以。 I've checked project build-path and javax.faces-2.1.14.jar is already added to the build-path.我已经检查了项目构建路径,并且javax.faces-2.1.14.jar已经添加到构建路径中。

Problem solved by adding JBoss Runtime Library to the classpath.通过将JBoss 运行时库添加到类路径解决了问题。

Eclipse: [Java Build Path -> Libraries -> Add Library -> Server Runtime -> JBoss Runtime]

I have no idea why the error only occurred when extending checkbox components.我不知道为什么只有在扩展复选框组件时才会发生错误。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM