{
    "content": [
        {
            "type": "text",
            "text": "# Test2::Event::V2 (perldoc)\n\n## NAME\n\nTest2::Event::V2 - Second generation event.\n\n## SYNOPSIS\n\nUSING A CONTEXT\nuse Test2::API qw/context/;\nsub mytool {\nmy $ctx = context();\nmy $event = $ctx->sendev2(info => [{tag => 'NOTE', details => \"This is a note\"}]);\n$ctx->release;\nreturn $event;\n}\nUSING THE CONSTRUCTOR\nuse Test2::Event::V2;\nmy $e = Test2::Event::V2->new(\ntrace => {frame => [$PKG, $FILE, $LINE, $SUBNAME]},\ninfo  => [{tag => 'NOTE', details => \"This is a note\"}],\n);\n\n## DESCRIPTION\n\nThis is the event type that should be used instead of Test2::Event or its legacy subclasses.\n\n## Sections\n\n- **NAME**\n- **DESCRIPTION**\n- **SYNOPSIS**\n- **METHODS**\n- **THIRD PARTY META-DATA**\n- **SOURCE**\n- **MAINTAINERS**\n- **AUTHORS**\n- **COPYRIGHT**\n\nUse structuredContent.sections for detailed options, examples, and full documentation.\n"
        }
    ],
    "structuredContent": {
        "command": "Test2::Event::V2",
        "section": "",
        "mode": "perldoc",
        "summary": "Test2::Event::V2 - Second generation event.",
        "synopsis": "USING A CONTEXT\nuse Test2::API qw/context/;\nsub mytool {\nmy $ctx = context();\nmy $event = $ctx->sendev2(info => [{tag => 'NOTE', details => \"This is a note\"}]);\n$ctx->release;\nreturn $event;\n}\nUSING THE CONSTRUCTOR\nuse Test2::Event::V2;\nmy $e = Test2::Event::V2->new(\ntrace => {frame => [$PKG, $FILE, $LINE, $SUBNAME]},\ninfo  => [{tag => 'NOTE', details => \"This is a note\"}],\n);",
        "tldr_summary": null,
        "tldr_examples": [],
        "tldr_source": null,
        "flags": [],
        "examples": [],
        "see_also": [],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SYNOPSIS",
                "lines": 21,
                "subsections": []
            },
            {
                "name": "METHODS",
                "lines": 53,
                "subsections": []
            },
            {
                "name": "THIRD PARTY META-DATA",
                "lines": 3,
                "subsections": []
            },
            {
                "name": "SOURCE",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "MAINTAINERS",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "AUTHORS",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "COPYRIGHT",
                "lines": 7,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "Test2::Event::V2 - Second generation event.\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "This is the event type that should be used instead of Test2::Event or its legacy subclasses.\n",
                "subsections": []
            },
            "SYNOPSIS": {
                "content": "USING A CONTEXT\nuse Test2::API qw/context/;\n\nsub mytool {\nmy $ctx = context();\n\nmy $event = $ctx->sendev2(info => [{tag => 'NOTE', details => \"This is a note\"}]);\n\n$ctx->release;\n\nreturn $event;\n}\n\nUSING THE CONSTRUCTOR\nuse Test2::Event::V2;\n\nmy $e = Test2::Event::V2->new(\ntrace => {frame => [$PKG, $FILE, $LINE, $SUBNAME]},\ninfo  => [{tag => 'NOTE', details => \"This is a note\"}],\n);\n",
                "subsections": []
            },
            "METHODS": {
                "content": "This class inherits from Test2::Event.\n\n$fd = $e->facetdata()\nThis will return a hashref of facet data. Each facet hash will be a shallow copy of the\noriginal.\n\n$about = $e->about()\nThis will return the 'about' facet hashref.\n\nNOTE: This will return the internal hashref, not a copy.\n\n$trace = $e->trace()\nThis will return the 'trace' facet, normally blessed (but this is not enforced when the\ntrace is set using \"settrace()\".\n\nNOTE: This will return the internal trace, not a copy.\n\nMUTATION\n$e->addamnesty({...})\nInherited from Test2::Event. This can be used to add 'amnesty' facets to an existing event.\nEach new item is added to the END of the list.\n\nNOTE: Items ARE blessed when added.\n\n$e->addhub({...})\nInherited from Test2::Event. This is used by hubs to stamp events as they pass through. New\nitems are added to the START of the list.\n\nNOTE: Items ARE NOT blessed when added.\n\n$e->setuuid($UUID)\nInherited from Test2::Event, overridden to also vivify/mutate the 'about' facet.\n\n$e->settrace($trace)\nInherited from Test2::Event which allows you to change the trace.\n\nNote: This method does not bless/clone the trace for you. Many things will expect the trace\nto be blessed, so you should probably do that.\n\nLEGACY SUPPORT METHODS\nThese are all imported from Test2::Util::Facets2Legacy, see that module or Test2::Event for\ndocumentation on what they do.\n\ncausesfail\ndiagnostics\nglobal\nincrementscount\nnodisplay\nsetsplan\nsubtestid\nsummary\nterminate\n",
                "subsections": []
            },
            "THIRD PARTY META-DATA": {
                "content": "This object consumes Test2::Util::ExternalMeta which provides a consistent way for you to attach\nmeta-data to instances of this class. This is useful for tools, plugins, and other extensions.\n",
                "subsections": []
            },
            "SOURCE": {
                "content": "The source code repository for Test2 can be found at http://github.com/Test-More/test-more/.\n",
                "subsections": []
            },
            "MAINTAINERS": {
                "content": "Chad Granum <exodist@cpan.org>\n",
                "subsections": []
            },
            "AUTHORS": {
                "content": "Chad Granum <exodist@cpan.org>\n",
                "subsections": []
            },
            "COPYRIGHT": {
                "content": "Copyright 2020 Chad Granum <exodist@cpan.org>.\n\nThis program is free software; you can redistribute it and/or modify it under the same terms as\nPerl itself.\n\nSee http://dev.perl.org/licenses/\n",
                "subsections": []
            }
        }
    }
}