{
    "mode": "perldoc",
    "parameter": "TAP::Parser::Iterator",
    "section": "",
    "url": "https://www.chedong.com/phpMan.php/perldoc/TAP%3A%3AParser%3A%3AIterator/json",
    "generated": "2026-06-09T14:57:53Z",
    "synopsis": "# to subclass:\nuse TAP::Parser::Iterator ();\nuse base 'TAP::Parser::Iterator';\nsub initialize {\n# see TAP::Object...\n}\nsub nextraw { ... }\nsub wait     { ... }\nsub exit     { ... }",
    "sections": {
        "NAME": {
            "content": "TAP::Parser::Iterator - Base class for TAP source iterators\n",
            "subsections": []
        },
        "VERSION": {
            "content": "Version 3.43\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "# to subclass:\nuse TAP::Parser::Iterator ();\nuse base 'TAP::Parser::Iterator';\nsub initialize {\n# see TAP::Object...\n}\n\nsub nextraw { ... }\nsub wait     { ... }\nsub exit     { ... }\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "This is a simple iterator base class that defines TAP::Parser's iterator API. Iterators are\ntypically created from TAP::Parser::SourceHandlers.\n",
            "subsections": []
        },
        "METHODS": {
            "content": "",
            "subsections": [
                {
                    "name": "Class Methods",
                    "content": "\"new\"\nCreate an iterator. Provided by TAP::Object.\n"
                },
                {
                    "name": "Instance Methods",
                    "content": "\"next\"\nwhile ( my $item = $iter->next ) { ... }\n\nIterate through it, of course.\n\n\"nextraw\"\nNote: this method is abstract and should be overridden.\n\nwhile ( my $item = $iter->nextraw ) { ... }\n\nIterate raw input without applying any fixes for quirky input syntax.\n\n\"handleunicode\"\nIf necessary switch the input stream to handle unicode. This only has any effect for I/O handle\nbased streams.\n\nThe default implementation does nothing.\n\n\"getselecthandles\"\nReturn a list of filehandles that may be used upstream in a select() call to signal that this\nIterator is ready. Iterators that are not handle-based should return an empty list.\n\nThe default implementation does nothing.\n\n\"wait\"\nNote: this method is abstract and should be overridden.\n\nmy $waitstatus = $iter->wait;\n\nReturn the \"wait\" status for this iterator.\n\n\"exit\"\nNote: this method is abstract and should be overridden.\n\nmy $waitstatus = $iter->exit;\n\nReturn the \"exit\" status for this iterator.\n"
                }
            ]
        },
        "SUBCLASSING": {
            "content": "Please see \"SUBCLASSING\" in TAP::Parser for a subclassing overview.\n\nYou must override the abstract methods as noted above.\n",
            "subsections": [
                {
                    "name": "Example",
                    "content": "TAP::Parser::Iterator::Array is probably the easiest example to follow. There's not much point\nrepeating it here.\n"
                }
            ]
        },
        "SEE ALSO": {
            "content": "TAP::Object, TAP::Parser, TAP::Parser::Iterator::Array, TAP::Parser::Iterator::Stream,\nTAP::Parser::Iterator::Process,\n",
            "subsections": []
        }
    },
    "summary": "TAP::Parser::Iterator - Base class for TAP source iterators",
    "flags": [],
    "examples": [],
    "see_also": []
}