3.33. kink/doc/model/SECTION

Provides sections in docs.

A section is a tree node of a kink doc.

The top level section corresponds to an entire doc.

The second level sections correspond to mods.

Sections on the third and further levels typically correspond to funs, types and methods.

3.33.1. SECTION.new(Title Blocks Subsections)

Makes a section.

Precondition:

* Title must be a str

* Blocks must be a vec of blocks

* Subsections must be a vec of sections

3.33.2. SECTION.section?(Val)

Returns whether Val is a section.

3.33.3. Type section

A section in a doc.

Section.op_eq(Another_section) and Section.op_ne(Another_section)

Two sections are equal when they have the same title, blocks and subsections.

Section.title

Returns the title of the section.

Section.blocks

Returns the blocks in the section.

Section.subsections

Returns the subsections of the section.