top | up | prev | next

InvokeNode Class

Definition at line 382 of Expression.hpp

Constructors

InvokeNode(const Span& span_, const boost::uuids::uuid& moduleId_)
InvokeNode(const Span& span_, const boost::uuids::uuid& moduleId_, Node* subject_)

Member Functions

void Accept(Visitor& visitor) override
void AddArgument(Node* argument) override
const NodeList<Node>& Arguments() const
Node* Clone(CloneContext& cloneContext) const override
void Read(AstReader& reader) override
const Node* Subject() const
Node* Subject()
std::string ToString() const override
void Write(AstWriter& writer) override

Member Variables

NodeList<Node> arguments
std::unique_ptr<Node> subject

Constructor Details

InvokeNode Constructor

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

Definition at line 906 of Expression.cpp :
 906 : Node(NodeType::invokeNodespan_moduleId_)subject()arguments()
 907 {
 908 }


Declaration at line 385 of Expression.hpp


InvokeNode Constructor

sngcm::ast::InvokeNode::InvokeNode(const Span& span_, const boost::uuids::uuid& moduleId_, Node * subject_)

Definition at line 910 of Expression.cpp :
 910 :
 911 Node(NodeType::invokeNodespan_moduleId_)subject(subject_)arguments()
 912 {
 913     subject->SetParent(this);
 914 }


Declaration at line 386 of Expression.hpp


Member Function Details

Accept Member Function

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

Definition at line 928 of Expression.cpp :
 929 {
 930     visitor.Visit(*this);
 931 }


Declaration at line 388 of Expression.hpp

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

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


AddArgument Member Function

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

Definition at line 949 of Expression.cpp :
 950 {
 951     argument->SetParent(this);
 952     arguments.Add(argument);
 953 }


Declaration at line 391 of Expression.hpp

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

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

Called by: sngcm::ast::InvokeNode::Clone


Arguments Member Function

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

Definition at line 394 of Expression.hpp :
394 { return arguments; }

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


Clone Member Function

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

Definition at line 916 of Expression.cpp :
 917 {
 918     InvokeNode* clone = new InvokeNode(GetSpan()ModuleId()subject->Clone(cloneContext));
 919     int n = arguments.Count();
 920     for (int i = 0; i < n; ++i)
 921     {
 922         Node* argument = arguments[i];
 923         clone->AddArgument(argument->Clone(cloneContext));
 924     }
 925     return clone;
 926 }


Declaration at line 387 of Expression.hpp

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

Calls: sngcm::ast::InvokeNode::AddArgument , sngcm::ast::InvokeNode::Clone , sngcm::ast::Node::Clone , sngcm::ast::Node::GetSpan , sngcm::ast::Node::ModuleId , sngcm::ast::NodeList::Count

Called by: sngcm::ast::InvokeNode::Clone


Read Member Function

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

Definition at line 940 of Expression.cpp :
 941 {
 942     Node::Read(reader);
 943     subject.reset(reader.ReadNode());
 944     subject->SetParent(this);
 945     arguments.Read(reader);
 946     arguments.SetParent(this);
 947 }


Declaration at line 390 of Expression.hpp

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

Calls: sngcm::ast::AstReader::ReadNode , sngcm::ast::Node::Read , sngcm::ast::Node::SetParent , sngcm::ast::NodeList::Read , sngcm::ast::NodeList::SetParent


Subject Member Function

const Node * sngcm::ast::InvokeNode::Subject() const

Definition at line 392 of Expression.hpp :
392 { return subject.get(); }


Subject Member Function

Node * sngcm::ast::InvokeNode::Subject()

Definition at line 393 of Expression.hpp :
393 { return subject.get(); }

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


ToString Member Function

std::string sngcm::ast::InvokeNode::ToString() const override

Definition at line 955 of Expression.cpp
Declaration at line 395 of Expression.hpp

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

Calls: sngcm::ast::InvokeNode::ToString , sngcm::ast::NodeList::Count

Called by: sngcm::ast::InvokeNode::ToString


Write Member Function

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

Definition at line 933 of Expression.cpp :
 934 {
 935     Node::Write(writer);
 936     writer.Write(subject.get());
 937     arguments.Write(writer);
 938 }


Declaration at line 389 of Expression.hpp

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

Calls: sngcm::ast::Node::Write , sngcm::ast::NodeList::Write


top | up | prev | next