If the specified contentBlock is a descendant of this instance.
If this instance equals another content block
An array representing all the node's attributes
Classification of the block. The value 'CONTAINER' implies that getChildren() can return items and that getTextContent() will return the empty string ''.
Further specifies the type of block within a block class.
List of all child blocks. Only contains items if
Get the content block tree this content block belongs to.
Get a ContentLocation for the complete or partial content block.
The character offset within the block's text content where the ContentLocation should start. Defaults to 0.
The number of characters to include. Defaults to end of textContent if omitted.
Get the id of this content block within the tree. The id can be used to fetch this content block again.
Note that the id is only unique within the reader document. Use getLocator() to get a UUID to this content block.
Get the nearest specified lang metadata for the content block. It starts looking for lang metadata on the current node and then traverses up the node tree until it finally falls back to the manifest language metadata.
Get a Locator for the complete or partial content block.
The character offset within the block's text content where the ContentLocation should start. Defaults to 0.
The number of characters to include. Defaults to end of textContent if omitted.
Get the ContentBlockMarkData items that further describes parts of the textContent, such as bold or italic text.
Get the next content block sibling if any.
Get the parent block if any.
Get the previous content block sibling if any.
Get media resource urls if blockClass is MEDIA
Get the text content for this content block. Does not include children.
Check if this instance is after another content block in document order.
Check if this instance is before another content block, in document order.
If this content block is a leaf node in the content block tree.
Get the content block as a plain object serializable to JSON
Generated using TypeDoc
Represents a single content block node in a document.
Note that implementations may create multiple objects representing the same logical content block. Therefore, do not use
==
or===
, instead use equals() to check if two content blocks are equal.