top | up | prev | next

WhereConstraintNode Class

Definition at line 73 of Concept.hpp

Constructors

WhereConstraintNode(const Span& span_)
WhereConstraintNode(const Span& span_, ConstraintNode* constraint_)

Member Functions

void Accept(Visitor& visitor) override
Node* Clone(CloneContext& cloneContext) const override
const ConstraintNode* Constraint() const
ConstraintNode* Constraint()
bool IsHeaderConstraint() const override
void Read(AstReader& reader) override
bool Semicolon() const
void SetHeaderConstraint()
void SetSemicolon()
std::string ToString() const override
void Write(AstWriter& writer) override

Member Variables

std::unique_ptr<ConstraintNode> constraint
bool headerConstraint
bool semicolon

Constructor Details

WhereConstraintNode Constructor

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

Definition at line 129 of Concept.cpp :
 129 : ConstraintNode(NodeType::whereConstraintNodespan_)constraint()headerConstraint(false)semicolon(false)
 130 {
 131 }


Declaration at line 76 of Concept.hpp


WhereConstraintNode Constructor

sngcm::ast::WhereConstraintNode::WhereConstraintNode(const Span& span_, ConstraintNode * constraint_)

Definition at line 133 of Concept.cpp :
 133 :
 134 ConstraintNode(NodeType::whereConstraintNodespan_)constraint(constraint_)headerConstraint(false)semicolon(false)
 135 {
 136     constraint->SetParent(this);
 137 }


Declaration at line 77 of Concept.hpp


Member Function Details

Accept Member Function

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

Definition at line 153 of Concept.cpp :
 154 {
 155     visitor.Visit(*this);
 156 }


Declaration at line 79 of Concept.hpp

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

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

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


Clone Member Function

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

Definition at line 139 of Concept.cpp
Declaration at line 78 of Concept.hpp

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

Calls: sngcm::ast::Node::GetSpan , sngcm::ast::WhereConstraintNode::Clone , sngcm::ast::WhereConstraintNode::SetHeaderConstraint , sngcm::ast::WhereConstraintNode::SetSemicolon

Called by: sngcm::ast::WhereConstraintNode::Clone


Constraint Member Function

const ConstraintNode * sngcm::ast::WhereConstraintNode::Constraint() const

Definition at line 82 of Concept.hpp :
 82 { return constraint.get(); }


Constraint Member Function

ConstraintNode * sngcm::ast::WhereConstraintNode::Constraint()

Definition at line 83 of Concept.hpp :
 83 { return constraint.get(); }

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


IsHeaderConstraint Member Function

bool sngcm::ast::WhereConstraintNode::IsHeaderConstraint() const override

Definition at line 86 of Concept.hpp :
 86 { return headerConstraint; }

Base class overridden functions: sngcm::ast::ConstraintNode::IsHeaderConstraint


Read Member Function

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

Definition at line 166 of Concept.cpp :
 167 {
 168     ConstraintNode::Read(reader);
 169     constraint.reset(reader.ReadConstraintNode());
 170     constraint->SetParent(this);
 171     headerConstraint = reader.GetBinaryReader().ReadBool();
 172     semicolon = reader.GetBinaryReader().ReadBool();
 173 }


Declaration at line 81 of Concept.hpp

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

Calls: sngcm::ast::AstReader::GetBinaryReader , sngcm::ast::AstReader::ReadConstraintNode , sngcm::ast::Node::Read , sngcm::ast::Node::SetParent , soulng::util::BinaryReader::ReadBool


Semicolon Member Function

bool sngcm::ast::WhereConstraintNode::Semicolon() const

Definition at line 88 of Concept.hpp :
 88 { return semicolon; }

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


SetHeaderConstraint Member Function

void sngcm::ast::WhereConstraintNode::SetHeaderConstraint()

Definition at line 85 of Concept.hpp :
 85 { headerConstraint = true; }

Called by: sngcm::ast::WhereConstraintNode::Clone


SetSemicolon Member Function

void sngcm::ast::WhereConstraintNode::SetSemicolon()

Definition at line 87 of Concept.hpp :
 87 { semicolon = true; }

Called by: sngcm::ast::WhereConstraintNode::Clone


ToString Member Function

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

Definition at line 175 of Concept.cpp :
 176 {
 177     return "where " + constraint->ToString();
 178 }


Declaration at line 84 of Concept.hpp

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

Calls: sngcm::ast::WhereConstraintNode::ToString

Called by: sngcm::ast::WhereConstraintNode::ToString


Write Member Function

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

Definition at line 158 of Concept.cpp :
 159 {
 160     ConstraintNode::Write(writer);
 161     writer.Write(constraint.get());
 162     writer.GetBinaryWriter().Write(headerConstraint);
 163     writer.GetBinaryWriter().Write(semicolon);
 164 }


Declaration at line 80 of Concept.hpp

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

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


top | up | prev | next