{
    "content": [
        {
            "type": "text",
            "text": "# HTTP::Server::Simple::CGI (perldoc)\n\n## NAME\n\nHTTP::Server::Simple::CGI - CGI.pm-style version of HTTP::Server::Simple\n\n## DESCRIPTION\n\nHTTP::Server::Simple was already simple, but some smart-ass pointed out that there is no CGI in\nHTTP, and so this module was born to isolate the CGI.pm-related parts of this handler.\n\n## Sections\n\n- **NAME**\n- **DESCRIPTION**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "HTTP::Server::Simple::CGI",
        "section": "",
        "mode": "perldoc",
        "summary": "HTTP::Server::Simple::CGI - CGI.pm-style version of HTTP::Server::Simple",
        "synopsis": null,
        "tldr_summary": null,
        "tldr_examples": [],
        "tldr_source": null,
        "flags": [],
        "examples": [],
        "see_also": [],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 54,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "HTTP::Server::Simple::CGI - CGI.pm-style version of HTTP::Server::Simple\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "HTTP::Server::Simple was already simple, but some smart-ass pointed out that there is no CGI in\nHTTP, and so this module was born to isolate the CGI.pm-related parts of this handler.\n\naccepthook\nThe accepthook in this sub-class clears the environment to the start-up state.\n\npostsetuphook\nInitializes the global CGI object, as well as other environment settings.\n\ncgiclass [Classname]\nGets or sets the class to use for creating the $cgi object passed to \"handlerequest\".\n\nCalled with a single argument, it sets the coderef. Called with no arguments, it returns this\nfield's current value.\n\nTo provide an initialization subroutine to be run in the postsetuphook, see \"cgiinit\".\n\ne.g.\n\n$server->cgiclass('CGI');\n\n$server->cgiinit(sub {\nrequire CGI;\nCGI::initializeglobals();\n});\n\nor, if you want to use CGI::Simple,\n\n$server->cgiclass('CGI::Simple');\n$server->cgiinit(sub {\nrequire CGI::Simple;\n});\n\ncgiinit [CODEREF]\nA coderef to run in the postsetuphook.\n\nCalled with a single argument, it sets the coderef. Called with no arguments, it returns this\nfield's current value.\n\nsetup\nThis method sets up CGI environment variables based on various meta-headers, like the protocol,\nremote host name, request path, etc.\n\nSee the docs in HTTP::Server::Simple for more detail.\n\nhandlerequest CGI\nThis routine is called whenever your server gets a request it can handle.\n\nIt's called with a CGI object that's been pre-initialized. You want to override this method in\nyour subclass\n\nhandler\nHandler implemented as part of HTTP::Server::Simple API\n",
                "subsections": []
            }
        }
    }
}