{
    "mode": "perldoc",
    "parameter": "XML::Grove::IDs",
    "section": "",
    "url": "https://www.chedong.com/phpMan.php/perldoc/XML%3A%3AGrove%3A%3AIDs/json",
    "generated": "2026-07-05T13:17:34Z",
    "synopsis": "use XML::Grove::IDs;\n# Using getids method on XML::Grove::Document or XML::Grove::Element:\n$hash = $groveobject->getids($attrname, $elements);\n# Using an XML::Grove::IDs instance:\n$indexer = XML::Grove::IDs->new($attrname, $elements);\nmy $hash = {};\n$groveobject->accept($indexer, $hash);",
    "sections": {
        "NAME": {
            "content": "XML::Grove::IDs - return an index of `id' attributes in a grove\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "use XML::Grove::IDs;\n\n# Using getids method on XML::Grove::Document or XML::Grove::Element:\n$hash = $groveobject->getids($attrname, $elements);\n\n# Using an XML::Grove::IDs instance:\n$indexer = XML::Grove::IDs->new($attrname, $elements);\nmy $hash = {};\n$groveobject->accept($indexer, $hash);\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "\"XML::Grove::IDs\" returns a hash index of all nodes in a grove with an `id' attribute. The keys\nof the hash are the ID attribute value and the value at that key is the element. `$attrname'\nand `$elements' are optional. The attribute name defaults to `\"id\"' if `$attrname' is not\nsupplied. Indexing can be restricted to only certain elements, by name, by providing a hash\ncontaining NAME=>1 values.\n",
            "subsections": []
        },
        "AUTHOR": {
            "content": "Ken MacLeod, ken@bitsko.slc.ut.us\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "",
            "subsections": [
                {
                    "name": "perl",
                    "content": "Extensible Markup Language (XML) <http://www.w3c.org/XML>\n"
                }
            ]
        }
    },
    "summary": "XML::Grove::IDs - return an index of `id' attributes in a grove",
    "flags": [],
    "examples": [],
    "see_also": []
}