top | up | prev | next

ConstructionStatementNode Class

Definition at line 262 of Statement.hpp

Constructors

ConstructionStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_)
ConstructionStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_, Node* typeExpr_, IdentifierNode* id_)

Member Functions

void Accept(Visitor& visitor) override
void AddArgument(Node* argument) override
const NodeList<Node>& Arguments() const
bool Assignment() const
Node* Clone(CloneContext& cloneContext) const override
bool Empty() const
const IdentifierNode* Id() const
IdentifierNode* Id()
void Read(AstReader& reader) override
void SetAssignment()
void SetEmpty()
const Node* TypeExpr() const
Node* TypeExpr()
void Write(AstWriter& writer) override

Member Variables

NodeList<Node> arguments
bool assignment
bool empty
std::unique_ptr<IdentifierNode> id
std::unique_ptr<Node> typeExpr

Constructor Details

ConstructionStatementNode Constructor

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

Definition at line 521 of Statement.cpp :
 521 :
 522 StatementNode(NodeType::constructionStatementNodespan_moduleId_)typeExpr()id()arguments()assignment(false)empty(false)
 523 {
 524 }


Declaration at line 265 of Statement.hpp


ConstructionStatementNode Constructor

sngcm::ast::ConstructionStatementNode::ConstructionStatementNode(const Span& span_, const boost::uuids::uuid& moduleId_, Node * typeExpr_, IdentifierNode * id_)

Definition at line 526 of Statement.cpp :
 526 :
 527 StatementNode(NodeType::constructionStatementNodespan_moduleId_)typeExpr(typeExpr_)id(id_)arguments()assignment(false)empty(false)
 528 {
 529     typeExpr->SetParent(this);
 530     if (id)
 531     {
 532         id->SetParent(this);
 533     }
 534 }


Declaration at line 266 of Statement.hpp


Member Function Details

Accept Member Function

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

Definition at line 549 of Statement.cpp :
 550 {
 551     visitor.Visit(*this);
 552 }


Declaration at line 268 of Statement.hpp

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

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


AddArgument Member Function

void sngcm::ast::ConstructionStatementNode::AddArgument(Node * argument) override

Definition at line 577 of Statement.cpp :
 578 {
 579     if (argument)
 580     {
 581         argument->SetParent(this);
 582         arguments.Add(argument);
 583     }
 584 }


Declaration at line 271 of Statement.hpp

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

Calls: sngcm::ast::Node::SetParent , sngcm::ast::NodeList::Add

Called by: sngcm::ast::ConstructionStatementNode::Clone


Arguments Member Function

const NodeList <Node >& sngcm::ast::ConstructionStatementNode::Arguments() const

Definition at line 276 of Statement.hpp :
276 { return arguments; }

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


Assignment Member Function

bool sngcm::ast::ConstructionStatementNode::Assignment() const

Definition at line 278 of Statement.hpp :
278 { return assignment; }

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


Clone Member Function

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

Definition at line 536 of Statement.cpp
Declaration at line 267 of Statement.hpp

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

Calls: sngcm::ast::ConstructionStatementNode::AddArgument , sngcm::ast::ConstructionStatementNode::Clone , sngcm::ast::ConstructionStatementNode::SetAssignment , sngcm::ast::ConstructionStatementNode::SetEmpty , sngcm::ast::Node::GetSpan , sngcm::ast::Node::ModuleId , sngcm::ast::NodeList::Count

Called by: sngcm::ast::ConstructionStatementNode::Clone


Empty Member Function

bool sngcm::ast::ConstructionStatementNode::Empty() const

Definition at line 280 of Statement.hpp :
280 { return empty; }

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


Id Member Function

const IdentifierNode * sngcm::ast::ConstructionStatementNode::Id() const

Definition at line 274 of Statement.hpp :
274 { return id.get(); }


Id Member Function

IdentifierNode * sngcm::ast::ConstructionStatementNode::Id()

Definition at line 275 of Statement.hpp :
275 { return id.get(); }

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


Read Member Function

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

Definition at line 564 of Statement.cpp
Declaration at line 270 of Statement.hpp

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

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


SetAssignment Member Function

void sngcm::ast::ConstructionStatementNode::SetAssignment()

Definition at line 277 of Statement.hpp :
277 { assignment = true; }

Called by: sngcm::ast::ConstructionStatementNode::Clone


SetEmpty Member Function

void sngcm::ast::ConstructionStatementNode::SetEmpty()

Definition at line 279 of Statement.hpp :
279 { empty = true; }

Called by: sngcm::ast::ConstructionStatementNode::Clone


TypeExpr Member Function

const Node * sngcm::ast::ConstructionStatementNode::TypeExpr() const

Definition at line 272 of Statement.hpp :
272 { return typeExpr.get(); }


TypeExpr Member Function

Node * sngcm::ast::ConstructionStatementNode::TypeExpr()

Definition at line 273 of Statement.hpp :
273 { return typeExpr.get(); }

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


Write Member Function

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

Definition at line 554 of Statement.cpp :
 555 {
 556     StatementNode::Write(writer);
 557     writer.Write(typeExpr.get());
 558     writer.Write(id.get());
 559     arguments.Write(writer);
 560     writer.GetBinaryWriter().Write(assignment);
 561     writer.GetBinaryWriter().Write(empty);
 562 }


Declaration at line 269 of Statement.hpp

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

Calls: sngcm::ast::AstWriter::GetBinaryWriter , sngcm::ast::NodeList::Write , sngcm::ast::StatementNode::Write , soulng::util::BinaryWriter::Write


top | up | prev | next