{
    "StateAttributesPy" : {
        "version": 1,
        "categories": "tutorials",
        "description": [
            "This is a tutorial node. It exercises state attributes to remember data from on evaluation to the next."
        ],
        "language": "python",
        "metadata":
        {
           "uiName": "Tutorial Python Node: State Attributes"
        },
        "inputs": { "ignored": { "type": "bool", "description": "Ignore me" } },
        "state": {
            "reset": {
                "type": "bool",
                "description": [
                    "If true then the inputs are ignored and outputs are set to default values, then this",
                    "flag is set to false for subsequent evaluations."
                ],
                "default": true
            },
            "monotonic": {
                "type": "int",
                "description": "The monotonically increasing output value, reset to 0 when the reset value is true"
            }
        },
        "$externalTest": [
            "This test infrastructure does not yet support multiple successive evaluations, so",
            "an external test script called 'test_tutorial_state_attributes_py.py' is used for that case.",
            "This test illustrates how a state value can be initialized before the test runs and checked after",
            "the test runs by using the _get and _set suffix on the state namespace. Having no suffix defaults to",
            "_get, where the expected state value is checked after running."
        ],
        "tests": [
            { "state_set:monotonic": 7, "state_get:reset": false, "state:monotonic": 8 }
        ]
    }
}
