HTML生成Java类库 ECS

fmms 10年前
     <p>ECS (<strong>Element Construction Set</strong>) 是一个用 Java 对象来生成 HTML 文档的工具包。</p>    <p>示例代码:</p>    <p><img border="0" hspace="0" alt="" src="" width="1" height="1" /></p>    <pre class="brush:java; toolbar: true; auto-links: false;">Html html = new Html()               .addElement(new Head()                   .addElement(new Title("Demo")))               .addElement(new Body()               .addElement(new H1("Demo Header"))               .addElement(new H3("Sub Header:"))               .addElement(new Font().setSize("+1")                          .setColor(HtmlColor.WHITE)                          .setFace("Times")                          .addElement("The big dog & the little cat chased each other."))); out.println(html.toString());  // or write to the outputstream directly output(out);</pre>    <p></p>    <p><strong>项目主页:</strong><a href="" target="_blank"></a></p>