如何生成facelets文档? [英] How to generate facelets documentation?

查看:106
本文介绍了如何生成facelets文档?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于JSP和某些 JSF标签,有一个名为 TLDdoc 为JSP和JSF标签生成JavaDoc样式的文档。



有没有人知道Facelets的等价物?有一个名为 facelets-doc 的工具,旨在支持Facelets,但尚未完成,或缺少文档没有提到如何使其工作。



我有一些面孔taglib.xml文件定义标签和函数,并希望得到类似于什么TLDdoc生成(示例)。有没有人知道TLDdoc是否支持Facelets?或者如果facelets-doc已经工作(如果是,如何)?或者是否存在另一种工具?

解决方案

最近几天,我已经分手了旧的TLDdoc,并将其改为/ - 将Facelets *。taglib.xml 文件完全支持到新项目中: Vdldoc 。生成的文档具有Java 7 javadoc look'n'feel。作为预览,请查看 OmniFaces VDL文档 PrimeFaces VDL文档



用法如下:

  VdldocGenerator generator = new VdldocGenerator(); 
generator.setWindowTitle(浏览器窗口标题); //将使用其它默认值。
generator.setDocTitle(文档标题); //将使用其它默认值。
generator.setOutputDirectory(new File(/ path / to / vdldoc)); // Else ./vdldoc将被使用。
generator.addTaglib(new File(/ path / to / foo.taglib.xml));
generator.addTaglib(new File(/ path / to / bar.taglib.xml));
// ...
generator.generate();

< facelet-taglib id> 将被用作taglib短名称:

 < facelet-taglib id =o> ; 
< description> OmniFaces UI组件。< / description>
< namespace> http://omnifaces.org/ui< / namespace>
...
< / facelet-taglib>

否则它将默认为基本文件名,而不包含 .taglib.xml extension。


For JSP and some JSF tags there is a tool called TLDdoc that generates JavaDoc-style documentation for the JSP and JSF tags.

Does anybody know an equivalent for Facelets? There is a tool called facelets-doc that aims to support Facelets but either it's not finished, or the lack of documentation doesn't mention how to make it work.

I have a few facelets taglib.xml files defining tags and functions and would love to get documentation similar to what TLDdoc generates (example).

Does anyone know if TLDdoc supports Facelets? Or if facelets-doc already works (and if yes, how)? Or if another tool exists for that?

解决方案

Last few days, I have forked the old TLDdoc and changed/rewritten it with near-complete support for Facelets *.taglib.xml files into a new project: Vdldoc. The generated documentation has Java 7 javadoc look'n'feel. As a preview, check the OmniFaces VDL documentation and PrimeFaces VDL documentation.

The usage is as follows:

VdldocGenerator generator = new VdldocGenerator();
generator.setWindowTitle("Browser window title"); // Else default will be used.
generator.setDocTitle("Documentation title"); // Else default will be used.
generator.setOutputDirectory(new File("/path/to/vdldoc")); // Else ./vdldoc will be used.
generator.addTaglib(new File("/path/to/foo.taglib.xml"));
generator.addTaglib(new File("/path/to/bar.taglib.xml"));
// ...
generator.generate();

The <facelet-taglib id> will be used as taglib short name:

<facelet-taglib id="o">
    <description>OmniFaces UI components.</description>
    <namespace>http://omnifaces.org/ui</namespace>
    ...
</facelet-taglib>

Otherwise it will default to the base filename without .taglib.xml extension.

这篇关于如何生成facelets文档?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆