top | up | prev | next

MemberVariableNode Class

Definition at line 174 of Class.hpp

Constructors

MemberVariableNode(const Span& span_)
MemberVariableNode(const Span& span_, Specifiers specifiers_, Node* typeExpr_, IdentifierNode* id_, Attributes* attributes_)

Member Functions

void Accept(Visitor& visitor) override
Node* Clone(CloneContext& cloneContext) const override
Attributes* GetAttributes() const
Specifiers GetSpecifiers() const override
IdentifierNode* Id() const
void Read(AstReader& reader) override
void SetSpecifierSpan(const Span& specifierSpan_)
const Span& SpecifierSpan() const
Node* TypeExpr() const
void Write(AstWriter& writer) override

Member Variables

std::unique_ptr<Attributes> attributes
std::unique_ptr<IdentifierNode> id
Span specifierSpan
Specifiers specifiers
std::unique_ptr<Node> typeExpr

Constructor Details

MemberVariableNode Constructor

sngcm::ast::MemberVariableNode::MemberVariableNode(const Span& span_)

Definition at line 489 of Class.cpp :
489 : Node(NodeType::memberVariableNodespan_)specifiers()
490 {
491 }


Declaration at line 177 of Class.hpp


MemberVariableNode Constructor

sngcm::ast::MemberVariableNode::MemberVariableNode(const Span& span_, Specifiers specifiers_, Node * typeExpr_, IdentifierNode * id_, Attributes * attributes_)

Definition at line 493 of Class.cpp :
493 :
494 Node(NodeType::memberVariableNodespan_)specifiers(specifiers_)typeExpr(typeExpr_)id(id_)attributes(attributes_)
495 {
496     typeExpr->SetParent(this);
497     id->SetParent(this);
498 }


Declaration at line 178 of Class.hpp


Member Function Details

Accept Member Function

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

Definition at line 512 of Class.cpp :
513 {
514     visitor.Visit(*this);
515 }


Declaration at line 180 of Class.hpp

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

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


Clone Member Function

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

Definition at line 500 of Class.cpp :
501 {
502     Attributes* clonedAttributes = nullptr;
503     if (attributes)
504     {
505         clonedAttributes = attributes->Clone();
506     }
507     MemberVariableNode* clone =  new MemberVariableNode(GetSpan()specifierstypeExpr->Clone(cloneContext)static_cast<IdentifierNode*>(id->Clone(cloneContext))clonedAttributes);
508     clone->SetSpecifierSpan(specifierSpan);
509     return clone;
510 }


Declaration at line 179 of Class.hpp

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

Calls: sngcm::ast::MemberVariableNode::Clone , sngcm::ast::MemberVariableNode::SetSpecifierSpan , sngcm::ast::Node::GetSpan

Called by: sngcm::ast::MemberVariableNode::Clone


GetAttributes Member Function

Attributes * sngcm::ast::MemberVariableNode::GetAttributes() const

Definition at line 186 of Class.hpp :
186 { return attributes.get(); }

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


GetSpecifiers Member Function

Specifiers sngcm::ast::MemberVariableNode::GetSpecifiers() const override

Definition at line 183 of Class.hpp :
183 { return specifiers; }

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

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


Id Member Function

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

Definition at line 185 of Class.hpp :
185 { return id.get(); }

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


Read Member Function

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

Definition at line 532 of Class.cpp
Declaration at line 182 of Class.hpp

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

Calls: sngcm::ast::AstReader::GetBinaryReader , sngcm::ast::AstReader::ReadIdentifierNode , sngcm::ast::AstReader::ReadNode , sngcm::ast::AstReader::ReadSpan , sngcm::ast::AstReader::ReadSpecifiers , sngcm::ast::MemberVariableNode::Read , sngcm::ast::Node::Read , sngcm::ast::Node::SetParent , soulng::util::BinaryReader::ReadBool

Called by: sngcm::ast::MemberVariableNode::Read


SetSpecifierSpan Member Function

void sngcm::ast::MemberVariableNode::SetSpecifierSpan(const Span& specifierSpan_)

Definition at line 187 of Class.hpp :
187 { specifierSpan = specifierSpan_; }

Called by: sngcm::ast::MemberVariableNode::Clone


SpecifierSpan Member Function

const Span& sngcm::ast::MemberVariableNode::SpecifierSpan() const

Definition at line 188 of Class.hpp :
188 { return specifierSpan; }


TypeExpr Member Function

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

Definition at line 184 of Class.hpp :
184 { return typeExpr.get(); }

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


Write Member Function

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

Definition at line 517 of Class.cpp
Declaration at line 181 of Class.hpp

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

Calls: sngcm::ast::AstWriter::GetBinaryWriter , sngcm::ast::AstWriter::Write , sngcm::ast::AstWriter::Write , sngcm::ast::MemberVariableNode::Write , sngcm::ast::Node::Write , soulng::util::BinaryWriter::Write

Called by: sngcm::ast::MemberVariableNode::Write


top | up | prev | next