The AbstractCharacterData class extends
AbstractNode
and represents nodes that contain character-based content. In the DOM context, such nodes are typically used for text and comments.
Since AbstractCharacterData extends AbstractNode, it inherits all the properties and methods of AbstractNode, providing basic node manipulation functionality. Additionally, it introduces methods specific to handling character data within nodes.
For example, character-based nodes like text or comments are primarily accessed or modified through these methods. These nodes are used in scenarios where textual content is part of the document, such as:
- A TextNode represents a node that contains text content within an element.
- A CommentNode contains a comment in the document.
Declaration
abstract class AbstractCharacterData extends AbstractNode
Methods
inherited methods
- appendChild
- clearChildNodes
- cloneNode
- getChild
- getChildNodes
- getFirstChild
- getLastChild
- getNextSibling
- getNodeId
- getNodeName
- getNodeType
- getParentElement
- getParentElements
- getParentNode
- getParentNodes
- getPreviousSibling
- hasChild
- hasSibling
- insertAfter
- insertBefore
- insertChildAtPosition
- isVisible
- moveAfterSibling
- moveBeforeSibling
- moveToFirstSibling
- moveToLastSibling
- moveToSiblingPosition
- prependChild
- removeChild
- render
- replaceChild
- setVisible
- sortChildNodes
- toJson