Package org.asciidoctor.jruby.ast.impl
Class SectionImpl
- java.lang.Object
-
- org.asciidoctor.jruby.internal.RubyObjectWrapper
-
- org.asciidoctor.jruby.ast.impl.ContentNodeImpl
-
- org.asciidoctor.jruby.ast.impl.StructuralNodeImpl
-
- org.asciidoctor.jruby.ast.impl.SectionImpl
-
- All Implemented Interfaces:
ContentNode,Section,StructuralNode
public class SectionImpl extends StructuralNodeImpl implements Section
-
-
Field Summary
-
Fields inherited from class org.asciidoctor.jruby.internal.RubyObjectWrapper
rubyNode, runtime
-
Fields inherited from interface org.asciidoctor.ast.StructuralNode
SUBSTITUTION_ATTRIBUTES, SUBSTITUTION_MACROS, SUBSTITUTION_POST_REPLACEMENTS, SUBSTITUTION_QUOTES, SUBSTITUTION_REPLACEMENTS, SUBSTITUTION_SPECIAL_CHARACTERS
-
-
Constructor Summary
Constructors Constructor Description SectionImpl(org.jruby.runtime.builtin.IRubyObject blockDelegate)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetIndex()java.lang.StringgetNumeral()Section numeral.java.lang.StringgetSectionName()java.lang.StringgetSectnum()Get the section number for the current Section.java.lang.StringgetSectnum(java.lang.String delimiter)Get the section number for the current Section.booleanisNumbered()booleanisSpecial()-
Methods inherited from class org.asciidoctor.jruby.ast.impl.StructuralNodeImpl
addSubstitution, append, convert, findBy, getBlocks, getCaption, getContent, getContentModel, getLevel, getSourceLocation, getStyle, getSubstitutions, getTitle, isSubstitutionEnabled, prependSubstitution, removeSubstitution, setCaption, setLevel, setStyle, setSubstitutions, setTitle
-
Methods inherited from class org.asciidoctor.jruby.ast.impl.ContentNodeImpl
addRole, getAttribute, getAttribute, getAttribute, getAttributes, getContext, getDocument, getId, getNodeName, getParent, getReftext, getRole, getRoles, hasAttribute, hasAttribute, hasRole, iconUri, imageUri, imageUri, isAttribute, isAttribute, isBlock, isInline, isOption, isReftext, isRole, mediaUri, normalizeWebPath, readAsset, removeRole, setAttribute, setContext, setId
-
Methods inherited from class org.asciidoctor.jruby.internal.RubyObjectWrapper
getBoolean, getInt, getList, getProperty, getRubyObject, getRubyProperty, getRuntime, getString, getSymbol, setBoolean, setInt, setRubyProperty, setString, setSymbol, toJava, toJava
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.asciidoctor.ast.ContentNode
addRole, getAttribute, getAttribute, getAttribute, getAttributes, getContext, getDocument, getId, getNodeName, getParent, getReftext, getRole, getRoles, hasAttribute, hasAttribute, hasRole, iconUri, imageUri, imageUri, isAttribute, isAttribute, isBlock, isInline, isOption, isReftext, isRole, mediaUri, normalizeWebPath, readAsset, removeRole, setAttribute, setContext, setId
-
Methods inherited from interface org.asciidoctor.ast.StructuralNode
addSubstitution, append, convert, findBy, getBlocks, getCaption, getContent, getContentModel, getLevel, getSourceLocation, getStyle, getSubstitutions, getTitle, isSubstitutionEnabled, prependSubstitution, removeSubstitution, setCaption, setLevel, setStyle, setSubstitutions, setTitle
-
-
-
-
Method Detail
-
getIndex
public int getIndex()
-
getNumeral
public java.lang.String getNumeral()
Description copied from interface:SectionSection numeral.This is a roman numeral for book parts, arabic numeral for regular sections, and a letter for special sections.
- Specified by:
getNumeralin interfaceSection- Returns:
- the section numeral
-
getSectionName
public java.lang.String getSectionName()
- Specified by:
getSectionNamein interfaceSection- Returns:
- the section name of this section
-
isSpecial
public boolean isSpecial()
-
isNumbered
public boolean isNumbered()
- Specified by:
isNumberedin interfaceSection- Returns:
- the state of the numbered attribute at this section (need to preserve for creating TOC)
-
getSectnum
public java.lang.String getSectnum()
Description copied from interface:SectionGet the section number for the current Section.The section number is a dot-separated String that uniquely describes the position of this Section in the document. Each entry represents a level of nesting. The value of each entry is the 1-based outline number of the Section amongst its numbered sibling Sections.
- Specified by:
getSectnumin interfaceSection
-
getSectnum
public java.lang.String getSectnum(java.lang.String delimiter)
Description copied from interface:SectionGet the section number for the current Section.The section number is a dot-separated String that uniquely describes the position of this Section in the document. Each entry represents a level of nesting. The value of each entry is the 1-based outline number of the Section amongst its numbered sibling Sections.
- Specified by:
getSectnumin interfaceSection- Parameters:
delimiter- the delimiter to separate the number for each level
-
-