本文整理汇总了Java中org.apache.maven.doxia.sink.Sink.sectionTitle3方法的典型用法代码示例。如果您正苦于以下问题:Java Sink.sectionTitle3方法的具体用法?Java Sink.sectionTitle3怎么用?Java Sink.sectionTitle3使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.apache.maven.doxia.sink.Sink
的用法示例。
在下文中一共展示了Sink.sectionTitle3方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: heading3WithAnchor
import org.apache.maven.doxia.sink.Sink; //导入方法依赖的package包/类
private void heading3WithAnchor(final Sink sink, final String anchor, final String text) {
sink.section3();
sink.sectionTitle3();
sink.anchor(anchor); sink.anchor_();
sink.text(text);
sink.sectionTitle3_();
sink.section3_();
}
示例2: reportDifferences
import org.apache.maven.doxia.sink.Sink; //导入方法依赖的package包/类
private void reportDifferences(List<ReportTimeReporter.DifferenceReport> diffs, Sink sink, ResourceBundle bundle,
String typeKey) {
if (diffs == null || diffs.isEmpty()) {
return;
}
sink.section3();
sink.sectionTitle3();
sink.text(bundle.getString(typeKey));
sink.sectionTitle3_();
sink.table();
sink.tableRow();
sink.tableHeaderCell();
sink.text(bundle.getString("report.revapi.difference.code"));
sink.tableHeaderCell_();
sink.tableHeaderCell();
sink.text(bundle.getString("report.revapi.difference.element"));
sink.tableHeaderCell_();
sink.tableHeaderCell();
sink.text(bundle.getString("report.revapi.difference.description"));
sink.tableHeaderCell_();
sink.tableRow_();
diffs.sort((d1, d2) -> {
String c1 = d1.difference.code;
String c2 = d2.difference.code;
int cmp = c1.compareTo(c2);
if (cmp != 0) {
return cmp;
}
Element e1 = d1.newElement == null ? d1.oldElement : d1.newElement;
Element e2 = d2.newElement == null ? d2.oldElement : d2.newElement;
cmp = e1.getClass().getName().compareTo(e2.getClass().getName());
if (cmp != 0) {
return cmp;
}
return e1.getFullHumanReadableString().compareTo(e2.getFullHumanReadableString());
});
for (ReportTimeReporter.DifferenceReport d : diffs) {
String element = d.oldElement == null ? (d.newElement.getFullHumanReadableString()) :
d.oldElement.getFullHumanReadableString();
sink.tableRow();
sink.tableCell();
sink.monospaced();
sink.text(d.difference.code);
sink.monospaced_();
sink.tableCell_();
sink.tableCell();
sink.monospaced();
sink.bold();
sink.text(element);
sink.bold_();
sink.monospaced_();
sink.tableCell();
sink.text(d.difference.description);
sink.tableCell_();
sink.tableRow_();
}
sink.table_();
sink.section3_();
}