top | up | prev | next

IfStatementNode Class

Definition at line 78 of Statement.hpp

Constructors

IfStatementNode()
IfStatementNode(const Span& span_, Node* condition_, Node* thenS_, Node* elseS_, const Span& elseSpan_)

Member Functions

void Accept(Visitor& visitor) override
Node* Condition()
Node* ElseS()
const Span& ElseSpan() const
void Read(Reader& reader) override
Node* ThenS()
void Write(Writer& writer) override

Member Variables

std::unique_ptr<Node> condition
std::unique_ptr<Node> elseS
Span elseSpan
std::unique_ptr<Node> thenS

Constructor Details

IfStatementNode Constructor

sngcpp::ast::IfStatementNode::IfStatementNode()

Definition at line 139 of Statement.cpp :
139 : Node(NodeType::ifStatementNode)
140 {
141 }


Declaration at line 81 of Statement.hpp


IfStatementNode Constructor

sngcpp::ast::IfStatementNode::IfStatementNode(const Span& span_, Node * condition_, Node * thenS_, Node * elseS_, const Span& elseSpan_)

Definition at line 143 of Statement.cpp :
143 :
144 Node(NodeType::ifStatementNodespan_)condition(condition_)thenS(thenS_)elseS(elseS_)elseSpan(elseSpan_)
145 {
146 }


Declaration at line 82 of Statement.hpp


Member Function Details

Accept Member Function

void sngcpp::ast::IfStatementNode::Accept(Visitor & visitor) override

Definition at line 148 of Statement.cpp :
149 {
150     visitor.Visit(*this);
151 }


Declaration at line 83 of Statement.hpp

Base class overridden functions: sngcpp::ast::Node::Accept

Calls: sngcpp::ast::Visitor::Visit


Condition Member Function

Node * sngcpp::ast::IfStatementNode::Condition()

Definition at line 86 of Statement.hpp :
 86 { return condition.get(); }


ElseS Member Function

Node * sngcpp::ast::IfStatementNode::ElseS()

Definition at line 88 of Statement.hpp :
 88 { return elseS.get(); }


ElseSpan Member Function

const Span& sngcpp::ast::IfStatementNode::ElseSpan() const

Definition at line 89 of Statement.hpp :
 89 { return elseSpan; }


Read Member Function

void sngcpp::ast::IfStatementNode::Read(Reader & reader) override

Definition at line 166 of Statement.cpp
Declaration at line 85 of Statement.hpp

Base class overridden functions: sngcpp::ast::Node::Read

Calls: sngcpp::ast::Node::Read , sngcpp::ast::Reader::GetBinaryReader , sngcpp::ast::Reader::Read , sngcpp::ast::Reader::ReadNode


ThenS Member Function

Node * sngcpp::ast::IfStatementNode::ThenS()

Definition at line 87 of Statement.hpp :
 87 { return thenS.get(); }


Write Member Function

void sngcpp::ast::IfStatementNode::Write(Writer & writer) override

Definition at line 153 of Statement.cpp
Declaration at line 84 of Statement.hpp

Base class overridden functions: sngcpp::ast::Node::Write

Calls: sngcpp::ast::IfStatementNode::Write , sngcpp::ast::Node::Write , sngcpp::ast::Writer::GetBinaryWriter , sngcpp::ast::Writer::Write

Called by: sngcpp::ast::IfStatementNode::Write


top | up | prev | next