Class SectionImpl

    • Constructor Detail

      • SectionImpl

        public SectionImpl​(org.jruby.runtime.builtin.IRubyObject blockDelegate)
    • Method Detail

      • getIndex

        public int getIndex()
        Specified by:
        getIndex in interface Section
        Returns:
        the 0-based index order of this section within the parent block
      • getNumeral

        public java.lang.String getNumeral()
        Description copied from interface: Section
        Section numeral.

        This is a roman numeral for book parts, arabic numeral for regular sections, and a letter for special sections.

        Specified by:
        getNumeral in interface Section
        Returns:
        the section numeral
      • getSectionName

        public java.lang.String getSectionName()
        Specified by:
        getSectionName in interface Section
        Returns:
        the section name of this section
      • isSpecial

        public boolean isSpecial()
        Specified by:
        isSpecial in interface Section
        Returns:
        Get the flag to indicate whether this is a special section or a child of one
      • isNumbered

        public boolean isNumbered()
        Specified by:
        isNumbered in interface Section
        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: Section
        Get 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:
        getSectnum in interface Section
      • getSectnum

        public java.lang.String getSectnum​(java.lang.String delimiter)
        Description copied from interface: Section
        Get 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:
        getSectnum in interface Section
        Parameters:
        delimiter - the delimiter to separate the number for each level