JSF1.2: difference between ui:repeat, a4j:repeat and t:datalist tags

。_饼干妹妹 提交于 2019-12-10 14:21:57

问题


Do you know what is the difference between the tags mentioned in the subject?

I thought they should produce pretty much the same result but it turned out that in some cases ui:repeat (a facelets tag) is not working as you would expect, although it's also considered a basic iteration component.

t is for tomahawk and a4j is a richfaces prefix.

Any comment is welcome.


回答1:


Facelets' ui:repeat has indeed bugs in certain situations. As to the difference with the other two, it boils down that it's not an UIData component while the other two are.

Ajax4jsf UIRepeat extends UIData.
Tomahawk's HtmlDataList extends UIData.
Facelets' UIRepeat does not extend UIData.

The inheritable codebase provided by UIData is pretty mature (although it is not always as efficient as it ought to be). The Facelets' UIRepeat still needs to be polished more. The ui:repeat can't extend UIData, because it's part of Facelets, the view technology, not of JSF, the component based MVC framework. It was also initially developed by a different team.

Since it's unclear what issue exactly you're talking about, it's hard to tell whether it's actually one of its known bugs or just a misinterpretation/abuse. At least, here is an overview of all known bugs related to ui:repeat.



来源:https://stackoverflow.com/questions/5023164/jsf1-2-difference-between-uirepeat-a4jrepeat-and-tdatalist-tags

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!