{
    "content": [
        {
            "type": "text",
            "text": "# XML::DOM::Text (perldoc)\n\n## NAME\n\nXML::DOM::Text - A piece of XML text in XML::DOM\n\n## DESCRIPTION\n\nXML::DOM::Text extends XML::DOM::CharacterData, which extends XML::DOM::Node.\n\n## Sections\n\n- **NAME**\n- **DESCRIPTION**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "XML::DOM::Text",
        "section": "",
        "mode": "perldoc",
        "summary": "XML::DOM::Text - A piece of XML text in XML::DOM",
        "synopsis": null,
        "tldr_summary": null,
        "tldr_examples": [],
        "tldr_source": null,
        "flags": [],
        "examples": [],
        "see_also": [],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 38,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "XML::DOM::Text - A piece of XML text in XML::DOM\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "XML::DOM::Text extends XML::DOM::CharacterData, which extends XML::DOM::Node.\n\nThe Text interface represents the textual content (termed character data in XML) of an Element\nor Attr. If there is no markup inside an element's content, the text is contained in a single\nobject implementing the Text interface that is the only child of the element. If there is\nmarkup, it is parsed into a list of elements and Text nodes that form the list of children of\nthe element.\n\nWhen a document is first made available via the DOM, there is only one Text node for each block\nof text. Users may create adjacent Text nodes that represent the contents of a given element\nwithout any intervening markup, but should be aware that there is no way to represent the\nseparations between these nodes in XML or HTML, so they will not (in general) persist between\nDOM editing sessions. The normalize() method on Element merges any such adjacent Text objects\ninto a single node for each block of text; this is recommended before employing operations that\ndepend on a particular document structure, such as navigation with XPointers.\n\nMETHODS\nsplitText (offset)\nBreaks this Text node into two Text nodes at the specified offset, keeping both in the tree\nas siblings. This node then only contains all the content up to the offset point. And a new\nText node, which is inserted as the next sibling of this node, contains all the content at\nand after the offset point.\n\nParameters: *offset* The offset at which to split, starting from 0.\n\nReturn Value: The new Text node.\n\nDOMExceptions:\n\n*   INDEXSIZEERR\n\nRaised if the specified offset is negative or greater than the number of characters in\ndata.\n\n*   NOMODIFICATIONALLOWEDERR\n\nRaised if this node is readonly.\n",
                "subsections": []
            }
        }
    }
}