top | up | prev | next

WStringLiteralNode Class

Definition at line 255 of Literal.hpp

Constructors

WStringLiteralNode(const Span& span_)
WStringLiteralNode(const Span& span_, const std::u16string& value_)

Member Functions

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

Member Variables

std::u16string value

Constructor Details

WStringLiteralNode Constructor

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

Definition at line 641 of Literal.cpp :
641 : LiteralNode(NodeType::wstringLiteralNodespan_)value()
642 {
643 }


Declaration at line 258 of Literal.hpp


WStringLiteralNode Constructor

sngcm::ast::WStringLiteralNode::WStringLiteralNode(const Span& span_, const std::u16string& value_)

Definition at line 645 of Literal.cpp :
645 : LiteralNode(NodeType::wstringLiteralNodespan_)value(value_)
646 {
647 }


Declaration at line 259 of Literal.hpp


Member Function Details

Accept Member Function

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

Definition at line 654 of Literal.cpp :
655 {
656     visitor.Visit(*this);
657 }


Declaration at line 261 of Literal.hpp

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

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


Clone Member Function

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

Definition at line 649 of Literal.cpp :
650 {
651     return new WStringLiteralNode(GetSpan()value);
652 }


Declaration at line 260 of Literal.hpp

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

Calls: sngcm::ast::Node::GetSpan


Read Member Function

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

Definition at line 665 of Literal.cpp :
666 {
667     LiteralNode::Read(reader);
668     value = reader.GetBinaryReader().ReadUtf16String();
669 }


Declaration at line 263 of Literal.hpp

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

Calls: sngcm::ast::AstReader::GetBinaryReader , sngcm::ast::LiteralNode::Read , soulng::util::BinaryReader::ReadUtf16String


ToString Member Function

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

Definition at line 671 of Literal.cpp :
672 {
673     return "\"" + StringStr(ToUtf8(value)) + "\"";
674 }


Declaration at line 264 of Literal.hpp

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


Value Member Function

const std::u16string& sngcm::ast::WStringLiteralNode::Value() const

Definition at line 265 of Literal.hpp :
265 { return value; }

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


Write Member Function

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

Definition at line 659 of Literal.cpp :
660 {
661     LiteralNode::Write(writer);
662     writer.GetBinaryWriter().Write(value);
663 }


Declaration at line 262 of Literal.hpp

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

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


top | up | prev | next