top | up | prev | next

ForStatementNode Class

Definition at line 196 of Statement.hpp

Constructors

ForStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_)
ForStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_, StatementNode* initS_, Node* condition_, StatementNode* loopS_, StatementNode* actionS_)

Member Functions

void Accept(Visitor& visitor) override
const StatementNode* ActionS() const
StatementNode* ActionS()
Node* Clone(CloneContext& cloneContext) const override
const Node* Condition() const
Node* Condition()
const StatementNode* InitS() const
StatementNode* InitS()
bool IsBreakEnclosingStatementNode() const override
bool IsContinueEnclosingStatementNode() const override
const Span& LeftParenSpan() const
const StatementNode* LoopS() const
StatementNode* LoopS()
void Read(AstReader& reader) override
const Span& RightParenSpan() const
void SetLeftParenSpan(const Span& leftParenSpan_)
void SetRightParenSpan(const Span& rightParenSpan_)
void Write(AstWriter& writer) override

Member Variables

std::unique_ptr<StatementNode> actionS
std::unique_ptr<Node> condition
std::unique_ptr<StatementNode> initS
Span leftParenSpan
std::unique_ptr<StatementNode> loopS
Span rightParenSpan

Constructor Details

ForStatementNode Constructor

sngcm::ast::ForStatementNode::ForStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_)

Definition at line 380 of Statement.cpp :
 380 :
 381 StatementNode(NodeType::forStatementNodespan_moduleId_)initS()condition()loopS()actionS()
 382 {
 383 }


Declaration at line 199 of Statement.hpp


ForStatementNode Constructor

sngcm::ast::ForStatementNode::ForStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_, StatementNode * initS_, Node * condition_, StatementNode * loopS_, StatementNode * actionS_)

Definition at line 385 of Statement.cpp
Declaration at line 200 of Statement.hpp


Member Function Details

Accept Member Function

void sngcm::ast::ForStatementNode::Accept(Visitor & visitor) override

Definition at line 417 of Statement.cpp :
 418 {
 419     visitor.Visit(*this);
 420 }


Declaration at line 202 of Statement.hpp

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

Calls: sngcm::ast::Visitor::Visit


ActionS Member Function

const StatementNode * sngcm::ast::ForStatementNode::ActionS() const

Definition at line 213 of Statement.hpp :
213 { return actionS.get(); }


ActionS Member Function

StatementNode * sngcm::ast::ForStatementNode::ActionS()

Definition at line 214 of Statement.hpp :
214 { return actionS.get(); }

Called by: sngcm::ast::SourceWriter::Visit


Clone Member Function

Node * sngcm::ast::ForStatementNode::Clone(CloneContext & cloneContext) const override

Definition at line 403 of Statement.cpp
Declaration at line 201 of Statement.hpp

Base class overridden functions: sngcm::ast::Node::Clone

Calls: sngcm::ast::ForStatementNode::Clone , sngcm::ast::ForStatementNode::SetLeftParenSpan , sngcm::ast::ForStatementNode::SetRightParenSpan , sngcm::ast::Node::GetSpan , sngcm::ast::Node::ModuleId

Called by: sngcm::ast::ForStatementNode::Clone


Condition Member Function

const Node * sngcm::ast::ForStatementNode::Condition() const

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


Condition Member Function

Node * sngcm::ast::ForStatementNode::Condition()

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

Called by: sngcm::ast::SourceWriter::Visit


InitS Member Function

const StatementNode * sngcm::ast::ForStatementNode::InitS() const

Definition at line 207 of Statement.hpp :
207 { return initS.get(); }


InitS Member Function

StatementNode * sngcm::ast::ForStatementNode::InitS()

Definition at line 208 of Statement.hpp :
208 { return initS.get(); }

Called by: sngcm::ast::SourceWriter::Visit


IsBreakEnclosingStatementNode Member Function

bool sngcm::ast::ForStatementNode::IsBreakEnclosingStatementNode() const override

Definition at line 205 of Statement.hpp :
205 { return true; }

Base class overridden functions: sngcm::ast::StatementNode::IsBreakEnclosingStatementNode


IsContinueEnclosingStatementNode Member Function

bool sngcm::ast::ForStatementNode::IsContinueEnclosingStatementNode() const override

Definition at line 206 of Statement.hpp :
206 { return true; }

Base class overridden functions: sngcm::ast::StatementNode::IsContinueEnclosingStatementNode


LeftParenSpan Member Function

const Span& sngcm::ast::ForStatementNode::LeftParenSpan() const

Definition at line 216 of Statement.hpp :
216 { return leftParenSpan; }


LoopS Member Function

const StatementNode * sngcm::ast::ForStatementNode::LoopS() const

Definition at line 211 of Statement.hpp :
211 { return loopS.get(); }


LoopS Member Function

StatementNode * sngcm::ast::ForStatementNode::LoopS()

Definition at line 212 of Statement.hpp :
212 { return loopS.get(); }

Called by: sngcm::ast::SourceWriter::Visit


Read Member Function

void sngcm::ast::ForStatementNode::Read(AstReader & reader) override

Definition at line 439 of Statement.cpp
Declaration at line 204 of Statement.hpp

Base class overridden functions: sngcm::ast::Node::Read , sngcm::ast::StatementNode::Read

Calls: sngcm::ast::AstReader::GetBinaryReader , sngcm::ast::AstReader::ReadNode , sngcm::ast::AstReader::ReadSpan , sngcm::ast::AstReader::ReadStatementNode , sngcm::ast::Node::SetParent , sngcm::ast::StatementNode::Read , soulng::util::BinaryReader::ReadBool


RightParenSpan Member Function

const Span& sngcm::ast::ForStatementNode::RightParenSpan() const

Definition at line 218 of Statement.hpp :
218 { return rightParenSpan; }


SetLeftParenSpan Member Function

void sngcm::ast::ForStatementNode::SetLeftParenSpan(const Span& leftParenSpan_)

Definition at line 215 of Statement.hpp :
215 { leftParenSpan = leftParenSpan_; }

Called by: sngcm::ast::ForStatementNode::Clone


SetRightParenSpan Member Function

void sngcm::ast::ForStatementNode::SetRightParenSpan(const Span& rightParenSpan_)

Definition at line 217 of Statement.hpp :
217 { rightParenSpan = rightParenSpan_; }

Called by: sngcm::ast::ForStatementNode::Clone


Write Member Function

void sngcm::ast::ForStatementNode::Write(AstWriter & writer) override

Definition at line 422 of Statement.cpp
Declaration at line 203 of Statement.hpp

Base class overridden functions: sngcm::ast::Node::Write , sngcm::ast::StatementNode::Write

Calls: sngcm::ast::AstWriter::GetBinaryWriter , sngcm::ast::AstWriter::SpanConversionModuleId , sngcm::ast::AstWriter::Write , sngcm::ast::Node::ModuleId , sngcm::ast::StatementNode::Write , soulng::util::BinaryWriter::Write


top | up | prev | next