risc::Definition Class Reference

#include <definition.h>

Inheritance diagram for risc::Definition:
Inheritance graph
[legend]

List of all members.

Public Types

enum  Type {
  CThreadType, ChannelType, ChannelInstanceType, ClassType,
  DefinitionType, EventType, FunctionType, HierarchicalChannelType,
  HierarchicalChannelInstanceType, InOutPortType, InPortType, InstanceType,
  InterfaceType, MethodType, ModuleType, ModuleInstanceType,
  ObjectType, OutPortType, PortType, PrimitiveChannelType,
  PrimitiveChannelInstanceType, ThreadType, VariableType
}
 

We are using these enums to identify type type of and instance or definition during traversal.

More...

Public Member Functions

 Definition (SgNode *ast_node, Type type=DefinitionType)
 default constructor
virtual std::string get_name ()
 Returns the name of the defintion.
virtual SgNode * get_ast_node ()
 Returns the associated ast node of the definition.
virtual SgType * get_ast_type ()
 Returns the type of the ast node.
virtual std::string get_ast_type_name ()
 Returns the name of the type of the ast node.
bool has_source_location ()
 Determines if a ast node has an associated ast node.
std::string get_file_name ()
 Get the name of the file where the declaration is located.
int get_line_number ()
 Get the line number of the instance.
int get_position_in_line ()
 Get the position of the in declaration in the corresponding line In other words the column in the line.

Public Attributes

Type type_
SgNode * ast_node_
SgType * ast_type_pointer_

Private Member Functions

 Definition (const Definition &rhs)

Member Enumeration Documentation

We are using these enums to identify type type of and instance or definition during traversal.

Enumerator:
CThreadType 
ChannelType 
ChannelInstanceType 
ClassType 
DefinitionType 
EventType 
FunctionType 
HierarchicalChannelType 
HierarchicalChannelInstanceType 
InOutPortType 
InPortType 
InstanceType 
InterfaceType 
MethodType 
ModuleType 
ModuleInstanceType 
ObjectType 
OutPortType 
PortType 
PrimitiveChannelType 
PrimitiveChannelInstanceType 
ThreadType 
VariableType 

Constructor & Destructor Documentation

risc::Definition::Definition ( SgNode *  ast_node,
Type  type = DefinitionType 
) [explicit]

default constructor

risc::Definition::Definition ( const Definition rhs  )  [private]

Member Function Documentation

SgNode * risc::Definition::get_ast_node (  )  [virtual]

Returns the associated ast node of the definition.

Reimplemented in risc::Class, risc::Function, and risc::Object.

SgType * risc::Definition::get_ast_type (  )  [virtual]

Returns the type of the ast node.

std::string risc::Definition::get_ast_type_name (  )  [virtual]
std::string risc::Definition::get_file_name (  ) 

Get the name of the file where the declaration is located.

Returns:
filename
int risc::Definition::get_line_number (  ) 

Get the line number of the instance.

Returns:
line number
std::string risc::Definition::get_name (  )  [virtual]

Returns the name of the defintion.

Reimplemented in risc::Class, risc::Function, and risc::Object.

int risc::Definition::get_position_in_line (  ) 

Get the position of the in declaration in the corresponding line In other words the column in the line.

Returns:
position in line
bool risc::Definition::has_source_location (  ) 

Determines if a ast node has an associated ast node.


Member Data Documentation


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 31 Jul 2017 by  doxygen 1.6.1