top | up | prev | next

HandlerNode Class

Definition at line 246 of Statement.hpp

Constructors

HandlerNode()
HandlerNode(const Span& span_, Node* exceptionDeclaration_, CompoundStatementNode* catchBlock_)

Member Functions

void Accept(Visitor& visitor) override
CompoundStatementNode* CatchBlock()
Node* ExceptionDeclaration()
void Read(Reader& reader) override
void Write(Writer& writer) override

Member Variables

std::unique_ptr<CompoundStatementNode> catchBlock
std::unique_ptr<Node> exceptionDeclaration

Constructor Details

HandlerNode Constructor

sngcpp::ast::HandlerNode::HandlerNode()

Definition at line 485 of Statement.cpp :
485 : Node(NodeType::handlerNode)
486 {
487 }


Declaration at line 249 of Statement.hpp


HandlerNode Constructor

sngcpp::ast::HandlerNode::HandlerNode(const Span& span_, Node * exceptionDeclaration_, CompoundStatementNode * catchBlock_)

Definition at line 489 of Statement.cpp :
489 :
490 Node(NodeType::handlerNodespan_)exceptionDeclaration(exceptionDeclaration_)catchBlock(catchBlock_)
491 {
492 }


Declaration at line 250 of Statement.hpp


Member Function Details

Accept Member Function

void sngcpp::ast::HandlerNode::Accept(Visitor & visitor) override

Definition at line 494 of Statement.cpp :
495 {
496     visitor.Visit(*this);
497 }


Declaration at line 251 of Statement.hpp

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

Calls: sngcpp::ast::Visitor::Visit


CatchBlock Member Function

CompoundStatementNode * sngcpp::ast::HandlerNode::CatchBlock()

Definition at line 255 of Statement.hpp :
255 { return catchBlock.get(); }


ExceptionDeclaration Member Function

Node * sngcpp::ast::HandlerNode::ExceptionDeclaration()

Definition at line 254 of Statement.hpp :
254 { return exceptionDeclaration.get(); }


Read Member Function

void sngcpp::ast::HandlerNode::Read(Reader & reader) override

Definition at line 506 of Statement.cpp :
507 {
508     Node::Read(reader);
509     exceptionDeclaration.reset(reader.ReadNode());
510     catchBlock.reset(reader.ReadCompoundStatementNode());
511 }


Declaration at line 253 of Statement.hpp

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

Calls: sngcpp::ast::Node::Read , sngcpp::ast::Reader::ReadCompoundStatementNode , sngcpp::ast::Reader::ReadNode


Write Member Function

void sngcpp::ast::HandlerNode::Write(Writer & writer) override

Definition at line 499 of Statement.cpp :
500 {
501     Node::Write(writer);
502     exceptionDeclaration->Write(writer);
503     catchBlock->Write(writer);
504 }


Declaration at line 252 of Statement.hpp

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

Calls: sngcpp::ast::HandlerNode::Write , sngcpp::ast::Node::Write

Called by: sngcpp::ast::HandlerNode::Write


top | up | prev | next