Record Class Heading
java.lang.Object
java.lang.Record
pro.verron.asciidoc.core.Heading
- Record Components:
header- AsciiDoc block headers containing optional informationlevel- heading level (1..6)inlines- inline fragments
- All Implemented Interfaces:
Block
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.header()Returns the value of theheaderrecord component.inlines()Returns the value of theinlinesrecord component.intlevel()Returns the value of thelevelrecord component.intsize()Returns the content size of this block.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Heading
Constructs aHeadingwithout block headers.- Parameters:
level- the heading level, must be between 1 and 6 (inclusive)inlines- the inline fragments representing the heading content- Throws:
IllegalArgumentException- if the heading level is outside the range 1..6
-
Heading
Constructs aHeadingwith block headers.- Parameters:
header- header elements, if anylevel- the heading level, must be between 1 and 6 (inclusive)inlines- the inline fragments representing the heading content- Throws:
IllegalArgumentException- if the heading level is outside the range 1..6
-
-
Method Details
-
size
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
header
-
level
-
inlines
-