Robot Framework
robot.parsing.model.visitor.ModelVisitor Class Reference

NodeVisitor that supports matching nodes based on their base classes. More...

Inheritance diagram for robot.parsing.model.visitor.ModelVisitor:
robot.parsing.model.visitor.VisitorFinder robot.parsing.model.blocks.FirstStatementFinder robot.parsing.model.blocks.LastStatementFinder robot.parsing.model.blocks.ModelValidator robot.parsing.model.blocks.ModelWriter robot.parsing.parser.parser.SetLanguages

Public Member Functions

def visit (self, node)
 

Detailed Description

NodeVisitor that supports matching nodes based on their base classes.

Otherwise identical to the standard `ast.NodeVisitor
<https://docs.python.org/library/ast.html#ast.NodeVisitor>`__,
but allows creating ``visit_ClassName`` methods so that the ``ClassName``
is one of the base classes of the node. For example, this visitor method
matches all statements::

    def visit_Statement(self, node):
        # ...

Definition at line 45 of file visitor.py.

Member Function Documentation

◆ visit()

def robot.parsing.model.visitor.ModelVisitor.visit (   self,
  node 
)

Definition at line 47 of file visitor.py.


The documentation for this class was generated from the following file: