top | up | prev | next

ParenthesizedConstraintNode Class

Definition at line 21 of Concept.hpp

Constructors

ParenthesizedConstraintNode(const Span& span_, const boost::uuids::uuid& moduleId_)
ParenthesizedConstraintNode(const Span& span_, const boost::uuids::uuid& moduleId_, ConstraintNode* constraint_)

Member Functions

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

Member Variables

std::unique_ptr<ConstraintNode> constraint

Constructor Details

ParenthesizedConstraintNode Constructor

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

Definition at line 20 of Concept.cpp :
  20 : ConstraintNode(NodeType::parenthesizedConstraintNodespan_moduleId_)
  21 {
  22 }


Declaration at line 24 of Concept.hpp


ParenthesizedConstraintNode Constructor

sngcm::ast::ParenthesizedConstraintNode::ParenthesizedConstraintNode(const Span& span_, const boost::uuids::uuid& moduleId_, ConstraintNode * constraint_)

Definition at line 24 of Concept.cpp :
  24 :
  25 ConstraintNode(NodeType::parenthesizedConstraintNodespan_moduleId_)constraint(constraint_)
  26 {
  27 }


Declaration at line 25 of Concept.hpp


Member Function Details

Accept Member Function

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

Definition at line 35 of Concept.cpp :
  36 {
  37     visitor.Visit(*this);
  38 }


Declaration at line 27 of Concept.hpp

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

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


Clone Member Function

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

Definition at line 29 of Concept.cpp :
  30 {
  31     ParenthesizedConstraintNode* clone = new ParenthesizedConstraintNode(GetSpan()ModuleId()static_cast<ConstraintNode*>(constraint->Clone(cloneContext)));
  32     return clone;
  33 }


Declaration at line 26 of Concept.hpp

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

Calls: sngcm::ast::Node::GetSpan , sngcm::ast::Node::ModuleId , sngcm::ast::ParenthesizedConstraintNode::Clone

Called by: sngcm::ast::ParenthesizedConstraintNode::Clone


Constraint Member Function

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

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


Constraint Member Function

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

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

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


Read Member Function

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

Definition at line 46 of Concept.cpp :
  47 {
  48     ConstraintNode::Read(reader);
  49     constraint.reset(reader.ReadConstraintNode());
  50 }


Declaration at line 29 of Concept.hpp

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

Calls: sngcm::ast::AstReader::ReadConstraintNode , sngcm::ast::Node::Read


ToString Member Function

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

Definition at line 52 of Concept.cpp :
  53 {
  54     return "(" + constraint->ToString() + ")";
  55 }


Declaration at line 32 of Concept.hpp

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

Calls: sngcm::ast::ParenthesizedConstraintNode::ToString

Called by: sngcm::ast::ParenthesizedConstraintNode::ToString


Write Member Function

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

Definition at line 40 of Concept.cpp :
  41 {
  42     ConstraintNode::Write(writer);
  43     writer.Write(constraint.get());
  44 }


Declaration at line 28 of Concept.hpp

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

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


top | up | prev | next