org.apache.maven.doxia.sink.Sink.section()方法的使用及代码示例

x33g5p2x  于2022-01-30 转载在 其他  
字(1.4k)|赞(0)|评价(0)|浏览(181)

本文整理了Java中org.apache.maven.doxia.sink.Sink.section()方法的一些代码示例,展示了Sink.section()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Sink.section()方法的具体详情如下:
包路径:org.apache.maven.doxia.sink.Sink
类名称:Sink
方法名:section

Sink.section介绍

暂无

代码示例

代码示例来源:origin: org.apache.maven.doxia/doxia-module-docbook-simple

private void handleSectionElements( Sink sink, String name, SinkEventAttributeSet attribs )
{
  //increase the nesting level
  level++;
  sink.section( level, attribs );
  parent.push( name );
}

代码示例来源:origin: org.xwiki.rendering/xwiki-rendering-syntax-doxia

@Override
public void beginHeader(HeaderLevel level, String id, Map<String, String> parameters)
{
  // Doxia has only 5 section levels!
  int levelAsInt = (level.getAsInt() < 6) ? level.getAsInt() : 5;
  this.sink.section(levelAsInt, null);
  this.sink.sectionTitle(levelAsInt, null);
  // Remember the header level for endSection() handling.
  this.headerLevel = level;
}

代码示例来源:origin: org.apache.maven.doxia/doxia-module-xdoc

private void handleSectionStart( int level, Sink sink, SinkEventAttributeSet attribs, XmlPullParser parser )
{
  consecutiveSections( level, sink );
  Object id = attribs.getAttribute( Attribute.ID.toString() );
  if ( id != null )
  {
    sink.anchor( id.toString() );
    sink.anchor_();
  }
  sink.section( level, attribs );
  sink.sectionTitle( level, null );
  sink.text( HtmlTools.unescapeHTML( parser.getAttributeValue( null, Attribute.NAME.toString() ) ) );
  sink.sectionTitle_( level );
}

相关文章