首页 > 解决方案 > 如何让 Eclipse JSF JBoss EL 提案在 BUILDING -not USING- JSF Composite Components 期间显示

问题描述

在Eclipse 中开发复合组件时,我希望 EL 提案能够像开发 facelet 时一样工作。

小面

<h:outputText value="#{purchaseOrderView.[JBoss EL proposes all attributes here that are available from the PurchaseOrderView.java class]}" />
<h:outputText value="#{purchaseOrderView.selectedOrder.[JBoss EL proposes all attributes here from the Order.java class]}" />

我知道 CC 没有显示任何提案,因为没有对具体对象的引用。

复合组件

<composite:interface>
    <composite:attribute name="viewBean"  />
</composite:interface>

    <h:outputText value="#{cc.attrs.viewBean.[No JBoss EL proposal]}" />
    <h:outputText value="#{cc.attrs.viewBean.selectedOrder.[No JBoss EL proposal]}" />

JBoss EL 怎么可能提供建议,它对 a 什么都不知道viewBean

那么有没有办法指定对具体对象的引用?我试过了,但这没有效果。

<composite:interface>
<composite:attribute name="viewBean" type="com.rozycki.fooApp.view.PurchaseOrderView" />
</composite:interface>

我认为当提案生效时,编码会更快、更容易。我的工作一直是开发为 facelet,然后转换为 CC。如果我重构任何与 CC 相关的 Java 代码,Eclipse 将不会在复合组件内部重构,这需要手动编辑。

这些缺陷似乎也适用于 ui:include 代码。

标签: eclipsejsfeljboss-tools

解决方案


推荐阅读