top | up | prev | next

MemberFunctionConstraintNode Class

Definition at line 205 of Concept.hpp

Constructors

MemberFunctionConstraintNode(const Span& span_, const boost::uuids::uuid& moduleId_)
MemberFunctionConstraintNode(const Span& span_, const boost::uuids::uuid& moduleId_, Node* returnTypeExpr_, IdentifierNode* typeParamId_, const std::u32string& groupId_)

Member Functions

void Accept(Visitor& visitor) override
void AddParameter(ParameterNode* parameter) override
Node* Clone(CloneContext& cloneContext) const override
const std::u32string& GroupId() const
const NodeList<ParameterNode>& Parameters() const
void Read(AstReader& reader) override
const Node* ReturnTypeExpr() const
Node* ReturnTypeExpr()
std::string ToString() const override
const IdentifierNode* TypeParamId() const
IdentifierNode* TypeParamId()
void Write(AstWriter& writer) override

Member Variables

std::u32string groupId
NodeList<ParameterNode> parameters
std::unique_ptr<Node> returnTypeExpr
std::unique_ptr<IdentifierNode> typeParamId

Constructor Details

MemberFunctionConstraintNode Constructor

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

Definition at line 489 of Concept.cpp :
 489 :
 490 SignatureConstraintNode(NodeType::memberFunctionConstraintNodespan_moduleId_)returnTypeExpr()typeParamId()groupId()parameters()
 491 {
 492 }


Declaration at line 208 of Concept.hpp


MemberFunctionConstraintNode Constructor

sngcm::ast::MemberFunctionConstraintNode::MemberFunctionConstraintNode(const Span& span_, const boost::uuids::uuid& moduleId_, Node * returnTypeExpr_, IdentifierNode * typeParamId_, const std::u32string& groupId_)

Definition at line 494 of Concept.cpp :
 494 :
 495 SignatureConstraintNode(NodeType::memberFunctionConstraintNodespan_moduleId_)returnTypeExpr(returnTypeExpr_)typeParamId(typeParamId_)groupId(groupId_)parameters()
 496 {
 497     returnTypeExpr->SetParent(this);
 498     typeParamId->SetParent(this);
 499 }


Declaration at line 209 of Concept.hpp


Member Function Details

Accept Member Function

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

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


Declaration at line 211 of Concept.hpp

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

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


AddParameter Member Function

void sngcm::ast::MemberFunctionConstraintNode::AddParameter(ParameterNode * parameter) override

Definition at line 538 of Concept.cpp :
 539 {
 540     parameter->SetParent(this);
 541     parameters.Add(parameter);
 542 }


Declaration at line 214 of Concept.hpp

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

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

Called by: sngcm::ast::MemberFunctionConstraintNode::Clone


Clone Member Function

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

Definition at line 501 of Concept.cpp :
 502 {
 503     MemberFunctionConstraintNode* clone = new MemberFunctionConstraintNode(GetSpan()ModuleId()returnTypeExpr->Clone(cloneContext)static_cast<IdentifierNode*>(typeParamId->Clone(cloneContext))groupId);
 504     int n = parameters.Count();
 505     for (int i = 0; i < n; ++i)
 506     {
 507         clone->AddParameter(static_cast<ParameterNode*>(parameters[i]->Clone(cloneContext)));
 508     }
 509     return clone;
 510 }


Declaration at line 210 of Concept.hpp

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

Calls: sngcm::ast::MemberFunctionConstraintNode::AddParameter , sngcm::ast::MemberFunctionConstraintNode::Clone , sngcm::ast::Node::GetSpan , sngcm::ast::Node::ModuleId , sngcm::ast::NodeList::Count

Called by: sngcm::ast::MemberFunctionConstraintNode::Clone


GroupId Member Function

const std::u32string& sngcm::ast::MemberFunctionConstraintNode::GroupId() const

Definition at line 219 of Concept.hpp :
219 { return groupId; }

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


Parameters Member Function

const NodeList <ParameterNode >& sngcm::ast::MemberFunctionConstraintNode::Parameters() const

Definition at line 220 of Concept.hpp :
220 { return parameters; }

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


Read Member Function

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

Definition at line 526 of Concept.cpp :
 527 {
 528     SignatureConstraintNode::Read(reader);
 529     returnTypeExpr.reset(reader.ReadNode());
 530     returnTypeExpr->SetParent(this);
 531     typeParamId.reset(reader.ReadIdentifierNode());
 532     typeParamId->SetParent(this);
 533     groupId = reader.GetBinaryReader().ReadUtf32String();
 534     parameters.Read(reader);
 535     parameters.SetParent(this);
 536 }


Declaration at line 213 of Concept.hpp

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

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


ReturnTypeExpr Member Function

const Node * sngcm::ast::MemberFunctionConstraintNode::ReturnTypeExpr() const

Definition at line 215 of Concept.hpp :
215 { return returnTypeExpr.get(); }


ReturnTypeExpr Member Function

Node * sngcm::ast::MemberFunctionConstraintNode::ReturnTypeExpr()

Definition at line 216 of Concept.hpp :
216 { return returnTypeExpr.get(); }

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


ToString Member Function

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

Definition at line 544 of Concept.cpp
Declaration at line 221 of Concept.hpp

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

Calls: sngcm::ast::MemberFunctionConstraintNode::ToString , sngcm::ast::Node::ToString , sngcm::ast::NodeList::Count , sngcm::ast::ParameterNode::TypeExpr

Called by: sngcm::ast::MemberFunctionConstraintNode::ToString


TypeParamId Member Function

const IdentifierNode * sngcm::ast::MemberFunctionConstraintNode::TypeParamId() const

Definition at line 217 of Concept.hpp :
217 { return typeParamId.get(); }


TypeParamId Member Function

IdentifierNode * sngcm::ast::MemberFunctionConstraintNode::TypeParamId()

Definition at line 218 of Concept.hpp :
218 { return typeParamId.get(); }

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


Write Member Function

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

Definition at line 517 of Concept.cpp :
 518 {
 519     SignatureConstraintNode::Write(writer);
 520     writer.Write(returnTypeExpr.get());
 521     writer.Write(typeParamId.get());
 522     writer.GetBinaryWriter().Write(groupId);
 523     parameters.Write(writer);
 524 }


Declaration at line 212 of Concept.hpp

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

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


top | up | prev | next