ROSE  0.11.96.11
Public Member Functions | List of all members
AbstractHandle::abstract_node Class Referenceabstract

Description

Users should provide a concrete node implementation especially a constructor/builder to avoid duplicated creation of abstract_node.

We try not to use pure virtual functions here to allow users to reuse the default implementation as much as possible

Definition at line 119 of file abstract_handle.h.

#include <abstract_handle.h>

Inheritance diagram for AbstractHandle::abstract_node:
Inheritance graph
[legend]

Public Member Functions

virtual std::string getConstructTypeName () const
 Get the construct' s type name, like function.
 
virtual bool hasSourcePos () const
 If the node has meaningful line and column numbers associated with a file.
 
virtual bool hasName () const
 If the node has legal names defined by language standards.
 
virtual std::string getName () const
 Get the name of the construct if it is named, like function name.
 
virtual abstract_nodegetFileNode () const
 Get the start source file position of the construct Get the abstract node for file containing the current node.
 
virtual abstract_nodegetParent () const
 Get parent node, used for generate parent handle automatically.
 
virtual void * getNode () const
 Get the raw IR node associated with the current abstract node.
 
virtual abstract_nodefindNode (std::string handle_str) const
 Find a node from a string for a abstract handle's string format, starting from this node eg. More...
 
virtual abstract_nodefindNode (std::string construct_type_str, specifier mspecifier) const
 Find a node of a given type, it also matches the specifier.
 
virtual std::string getFileName () const
 
virtual source_position_pair getSourcePos () const
 
virtual source_position getStartPos () const
 
virtual source_position getEndPos () const
 
virtual std::string toString () const
 
virtual size_t getIntLabel () const
 Get integer label.
 
virtual std::string getStringLabel () const
 Get string label.
 
virtual size_t getNumbering (const abstract_node *another_node) const
 Get the ordering of the construct relative to another construct in a higher scope Numbering start from 1 e.g. More...
 
virtual bool operator== (const abstract_node &x) const =0
 

Member Function Documentation

◆ findNode()

virtual abstract_node* AbstractHandle::abstract_node::findNode ( std::string  handle_str) const
virtual

Find a node from a string for a abstract handle's string format, starting from this node eg.

find a file node from a string like SourceFile<name,/home/liao6/names.cpp>

◆ getNumbering()

virtual size_t AbstractHandle::abstract_node::getNumbering ( const abstract_node another_node) const
virtual

Get the ordering of the construct relative to another construct in a higher scope Numbering start from 1 e.g.

a function construct may be the 2nd function relative to a file

Reimplemented in AbstractHandle::roseNode.


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