top | up | prev | next

IsConstraintNode Class

Definition at line 111 of Concept.hpp

Constructors

IsConstraintNode(const Span& span_)
IsConstraintNode(const Span& span_, Node* typeExpr_, Node* conceptOrTypeName_)

Member Functions

void Accept(Visitor& visitor) override
Node* Clone(CloneContext& cloneContext) const override
const Node* ConceptOrTypeName() const
Node* ConceptOrTypeName()
void Read(AstReader& reader) override
std::string ToString() const override
const Node* TypeExpr() const
Node* TypeExpr()
void Write(AstWriter& writer) override

Member Variables

std::unique_ptr<Node> conceptOrTypeName
std::unique_ptr<Node> typeExpr

Constructor Details

IsConstraintNode Constructor

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

Definition at line 217 of Concept.cpp :
 217 : ConstraintNode(NodeType::isConstraintNodespan_)typeExpr()conceptOrTypeName()
 218 {
 219 }


Declaration at line 114 of Concept.hpp


IsConstraintNode Constructor

sngcm::ast::IsConstraintNode::IsConstraintNode(const Span& span_, Node * typeExpr_, Node * conceptOrTypeName_)

Definition at line 221 of Concept.cpp :
 221 :
 222 ConstraintNode(NodeType::isConstraintNodespan_)typeExpr(typeExpr_)conceptOrTypeName(conceptOrTypeName_)
 223 {
 224     typeExpr->SetParent(this);
 225     conceptOrTypeName->SetParent(this);
 226 }


Declaration at line 115 of Concept.hpp


Member Function Details

Accept Member Function

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

Definition at line 233 of Concept.cpp :
 234 {
 235     visitor.Visit(*this);
 236 }


Declaration at line 117 of Concept.hpp

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

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


Clone Member Function

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

Definition at line 228 of Concept.cpp :
 229 {
 230     return new IsConstraintNode(GetSpan()typeExpr->Clone(cloneContext)conceptOrTypeName->Clone(cloneContext));
 231 }


Declaration at line 116 of Concept.hpp

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

Calls: sngcm::ast::IsConstraintNode::Clone , sngcm::ast::Node::GetSpan

Called by: sngcm::ast::IsConstraintNode::Clone


ConceptOrTypeName Member Function

const Node * sngcm::ast::IsConstraintNode::ConceptOrTypeName() const

Definition at line 122 of Concept.hpp :
122 { return conceptOrTypeName.get(); }


ConceptOrTypeName Member Function

Node * sngcm::ast::IsConstraintNode::ConceptOrTypeName()

Definition at line 123 of Concept.hpp :
123 { return conceptOrTypeName.get(); }

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


Read Member Function

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

Definition at line 245 of Concept.cpp :
 246 {
 247     ConstraintNode::Read(reader);
 248     typeExpr.reset(reader.ReadNode());
 249     typeExpr->SetParent(this);
 250     conceptOrTypeName.reset(reader.ReadNode());
 251     conceptOrTypeName->SetParent(this);
 252 }


Declaration at line 119 of Concept.hpp

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

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


ToString Member Function

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

Definition at line 254 of Concept.cpp :
 255 {
 256     return typeExpr->ToString() + " is " + conceptOrTypeName->ToString();
 257 }


Declaration at line 124 of Concept.hpp

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

Calls: sngcm::ast::IsConstraintNode::ToString

Called by: sngcm::ast::IsConstraintNode::ToString


TypeExpr Member Function

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

Definition at line 120 of Concept.hpp :
120 { return typeExpr.get(); }


TypeExpr Member Function

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

Definition at line 121 of Concept.hpp :
121 { return typeExpr.get(); }

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


Write Member Function

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

Definition at line 238 of Concept.cpp :
 239 {
 240     ConstraintNode::Write(writer);
 241     writer.Write(typeExpr.get());
 242     writer.Write(conceptOrTypeName.get());
 243 }


Declaration at line 118 of Concept.hpp

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

Calls: sngcm::ast::Node::Write


top | up | prev | next