top | up | prev | next

NamespaceSymbol Class

Definition at line 12 of NamespaceSymbol.hpp

Constructors

NamespaceSymbol(const Span& span_, const boost::uuids::uuid& sourceModuleId_, const std::u32string& name_)

Member Functions

const char* ClassName() const override
std::unique_ptr<Element> CreateDomElement(TypeMap& typeMap) override
std::string GetSymbolCategoryDescription() const override
std::string GetSymbolCategoryStr() const override
std::u32string Id() const override
void Import(NamespaceSymbol* that, SymbolTable& symbolTable)
std::u32string Info() const override
bool IsGlobalNamespace() const
bool IsParentSymbol() const override
std::string TypeString() const override

Constructor Details

NamespaceSymbol Constructor

cmajor::symbols::NamespaceSymbol::NamespaceSymbol(const Span& span_, const boost::uuids::uuid& sourceModuleId_, const std::u32string& name_)

Definition at line 12 of NamespaceSymbol.cpp :
12 :
13 ContainerSymbol(SymbolType::namespaceSymbolspan_sourceModuleId_name_)
14 {
15 }


Declaration at line 15 of NamespaceSymbol.hpp


Member Function Details

ClassName Member Function

const char * cmajor::symbols::NamespaceSymbol::ClassName() const override

Definition at line 23 of NamespaceSymbol.hpp :
23 { return "NamespaceSymbol"; }

Base class overridden functions: cmajor::symbols::ContainerSymbol::ClassName , cmajor::symbols::Symbol::ClassName


CreateDomElement Member Function

std::unique_ptr<Element > cmajor::symbols::NamespaceSymbol::CreateDomElement(TypeMap & typeMap) override

Definition at line 52 of NamespaceSymbol.cpp :
53 {
54     if (HasProjectMembers() && Access() != SymbolAccess::private_)
55     {
56         return std::unique_ptr<sngxml::dom::Element>(new sngxml::dom::Element(U"NamespaceSymbol"));
57     }
58     else
59     {
60         return std::unique_ptr<sngxml::dom::Element>();
61     }
62 }


Declaration at line 21 of NamespaceSymbol.hpp

Base class overridden functions: cmajor::symbols::Symbol::CreateDomElement

Calls: cmajor::symbols::ContainerSymbol::HasProjectMembers , cmajor::symbols::Symbol::Access


GetSymbolCategoryDescription Member Function

std::string cmajor::symbols::NamespaceSymbol::GetSymbolCategoryDescription() const override

Definition at line 25 of NamespaceSymbol.hpp :
25 { return "namespace"; }

Base class overridden functions: cmajor::symbols::Symbol::GetSymbolCategoryDescription


GetSymbolCategoryStr Member Function

std::string cmajor::symbols::NamespaceSymbol::GetSymbolCategoryStr() const override

Definition at line 24 of NamespaceSymbol.hpp :
24 { return "NS"; }

Base class overridden functions: cmajor::symbols::Symbol::GetSymbolCategoryStr


Id Member Function

std::u32string cmajor::symbols::NamespaceSymbol::Id() const override

Definition at line 17 of NamespaceSymbol.hpp :
17 { return U"ns_" + FullName(); }

Base class overridden functions: cmajor::symbols::Symbol::Id

Calls: cmajor::symbols::Symbol::FullName


Import Member Function

void cmajor::symbols::NamespaceSymbol::Import(NamespaceSymbol * that, SymbolTable & symbolTable)

Definition at line 17 of NamespaceSymbol.cpp
Declaration at line 19 of NamespaceSymbol.hpp

Calls: cmajor::symbols::ContainerSymbol::AddOwnedMember , cmajor::symbols::ContainerSymbol::Members , cmajor::symbols::NamespaceSymbol::Import , cmajor::symbols::Symbol::GetSpan , cmajor::symbols::Symbol::GetSymbolType , cmajor::symbols::Symbol::Name , cmajor::symbols::Symbol::SourceModuleId , cmajor::symbols::SymbolTable::BeginNamespace , cmajor::symbols::SymbolTable::Container , cmajor::symbols::SymbolTable::EndNamespace , cmajor::symbols::SymbolTable::MapNs

Called by: cmajor::symbols::NamespaceSymbol::Import , cmajor::symbols::SymbolTable::Import


Info Member Function

std::u32string cmajor::symbols::NamespaceSymbol::Info() const override

Definition at line 22 of NamespaceSymbol.hpp :
22 { return Name(); }

Base class overridden functions: cmajor::symbols::Symbol::Info

Calls: cmajor::symbols::Symbol::Name


IsGlobalNamespace Member Function

bool cmajor::symbols::NamespaceSymbol::IsGlobalNamespace() const

Definition at line 20 of NamespaceSymbol.hpp :
20 { return Name().empty(); }

Calls: cmajor::symbols::Symbol::Name


IsParentSymbol Member Function

bool cmajor::symbols::NamespaceSymbol::IsParentSymbol() const override

Definition at line 18 of NamespaceSymbol.hpp :
18 { return true; }

Base class overridden functions: cmajor::symbols::Symbol::IsParentSymbol


TypeString Member Function

std::string cmajor::symbols::NamespaceSymbol::TypeString() const override

Definition at line 16 of NamespaceSymbol.hpp :
16 { return "namespace"; }

Base class overridden functions: cmajor::symbols::ContainerSymbol::TypeString , cmajor::symbols::Symbol::TypeString


top | up | prev | next