Interpreter prototype alpha
c++ interpreter for make believe language
 
Loading...
Searching...
No Matches
ifNode Class Reference

creates a node in the syntax tree of type ifNode More...

#include <ifNode.h>

Inheritance diagram for ifNode:
tokenNode

Public Member Functions

 ifNode ()
 constructor
 
std::string __represent__ ()
 (virtual) returns a string representing the current state of this ifNode and it's syntax tree structure
 
void appendNew__If__ElseIf__Else__statement (const std::shared_ptr< ifNode > &token)
 appends an ifnode to the end of this ifnodes linked list of ifnodes
 
- Public Member Functions inherited from tokenNode
 tokenNode ()
 constructor
 
virtual std::string __represent__ ()=0
 (virtual) returns a string representing the current state of the syntax tree
 

Public Attributes

std::string conditionaltype = ""
 conditional type whether word or number types
 
std::string datatype
 data type whether word or number types
 
std::shared_ptr< tokenNodecondition = nullptr
 condition of this ifNode (only for if and elseif, excluding else)
 
std::shared_ptr< tokenNodenext__If__ElseIf__Else = nullptr
 pointer to next elseif or else statement (doesn't apply to else statemments)
 
std::vector< expressionDatastatementsvect
 the statements vector this if node code block to execute if the condition is deemed true
 
- Public Attributes inherited from tokenNode
std::string nodeType = "None"
 used for directing execution in the syntax tree
 

Detailed Description

creates a node in the syntax tree of type ifNode

Author
Michael

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