This class holds an alib::StringTree of all tags found in a doxygen tag-file. In addition, a non-unique hash-map is created that allows to find entities in O(1).
#include <index.hpp>
Inner Type Index: | |
| struct | AnchorKey |
| A pod-like struct providing the key for the hash table found in the field Index::anchorMap. More... | |
| struct | Node |
| The cursor type of the StringTree. More... | |
| struct | Parser |
| Internal struct that parses a tag-file. Used by the method loadTagFile. More... | |
| struct | SearchResult |
| An entry in the vector of search results generated by the method Search. More... | |
Public Field Index: | |
| const alib::String & | BaseURL |
| The URL of the HTML-output created with this tag-file. | |
| alib::system::PathString | FileName |
| The base name component of FilePath. | |
| alib::system::PathString | FilePath |
| The path to the doxygenTagFile. | |
| const bool | IsMainTagFile |
| Target::KindStats | KindStats |
| Statistics on the number of entities found per kind in Target::Kinds. | |
| alib::Ticks::Duration | LoadTime |
| A timestamp set when loaded. | |
| alib::SharedLock | SLock |
| int | StatCtdLines |
| Statistics on the number of lines in the tag-file. | |
Protected Type Index: | |
| using | TreeType = StringTree |
| The type of the string tree that holds the tag-file. | |
| Protected Type Index: inherited from alib::containers::detail::StringTreeBase< TAllocator, T, TNodeHandler, TRecycling > | |
| typedef typename TNodeHandler::CharacterType | CharacterType |
| typedef TCursorBase< true > | ConstCursorBase |
| typedef TCursorBase< false > | CursorBase |
| typedef typename TNodeHandler::NameStringType | NameStorageType |
| typedef const strings::TString< CharacterType > | NameType |
| typedef lang::BidiListHook< NodeBase > | NodeList |
| typedef typename decltype(nodeTable)::SharedRecyclerType | SharedRecyclerType |
| typedef typename strings::TSubstring< CharacterType > | SubstringType |
Protected Field Index: | |
| alib::containers::HashMap< alib::MonoAllocator, AnchorKey, CursorHandle, AnchorKey::Hash, std::equal_to< AnchorKey >, alib::lang::Caching::Enabled > | anchorMap |
| Maps HTML-files found to their corresponding tree nodes. | |
| alib::containers::HashMap< alib::MonoAllocator, alib::String, CursorHandle > | entityMap |
| alib::containers::HashMap< alib::MonoAllocator, const alib::String &, CursorHandle, std::hash< alib::String >, std::equal_to< const alib::String >, alib::lang::Caching::Disabled, alib::Recycling::None > | fileMap |
| Maps HTML-files found to their corresponding tree nodes. | |
| alib::String | fileNameDotComponents [10] |
| int | fileNameDotComponentsSize |
| The number of components in fileNameDotComponents. | |
| alib::MonoAllocator | ma |
| The allocator used for the parent StringTree and for the hashtable in the field map. | |
| Protected Field Index: inherited from alib::containers::detail::StringTreeBase< TAllocator, T, TNodeHandler, TRecycling > | |
| int | dbgRootDataSet |
| HashTable< TAllocator, typename NodeKey::ValueDescriptor, typename NodeKey::Hash, typename NodeKey::EqualTo, lang::Caching::Enabled, TRecycling > | nodeTable |
| RootNodeSpacer | root |
| CharacterType | separator |
Protected Method Index: | |
| void | dedupGroupEntries (alib::StdVectorMA< SearchResult > &targets) |
| void | evaluateEntity (XLink &xLink, Node node, bool isIndirectByInheritance, bool isIndirectByTypeDef) |
| void | loadTagFile () |
| Loads the tag-file. This is called by Load. | |
| void | searchFile (XLink &xLink) |
| Protected Method Index: inherited from alib::containers::StringTree< alib::MonoAllocator, Target *, alib::containers::StringTreeNamesAlloc<> > | |
| Cursor | createCursor (baseNode &node) |
| Protected Method Index: inherited from alib::containers::detail::StringTreeBase< TAllocator, T, TNodeHandler, TRecycling > | |
| StringTreeBase (TAllocator &allocator, CharacterType pathSeparator) | |
| bool | checkChildName (const NameType &name) const |
| TAllocator & | GetAllocator () noexcept |
Additional Inherited Members | |
| Public Type Index: inherited from alib::containers::StringTree< alib::MonoAllocator, Target *, alib::containers::StringTreeNamesAlloc<> > | |
| typedef TAllocator | AllocatorType |
| typedef typename TNodeHandler::CharacterType | CharacterType |
| typedef TCursor< true > | ConstCursor |
| typedef TCursor< false > | Cursor |
| typedef TNodeHandler | HandlerType |
| typedef strings::TString< CharacterType > | NameType |
| typedef typename basetree::SharedRecyclerType | SharedRecyclerType |
| typedef typename strings::TSubstring< CharacterType > | SubstringType |
|
protected |
|
protected |
| const alib::String& dxl::Index::BaseURL |
|
protected |
The hashmap providing an index to tree nodes by their name. For some compound types, for example, those that represent overloaded methods in C++, the tree node name string contains additional information like parameter types or method qualifiers. Those are stripped before inserted into this map. Thus, this table contains multiple entries and has to be fed and queried using the according set of interface methods.
|
protected |
| alib::system::PathString dxl::Index::FileName |
|
protected |
|
protected |
| alib::system::PathString dxl::Index::FilePath |
| const bool dxl::Index::IsMainTagFile |
| Target::KindStats dxl::Index::KindStats |
Statistics on the number of entities found per kind in Target::Kinds.
| alib::Ticks::Duration dxl::Index::LoadTime |
|
protected |
The allocator used for the parent StringTree and for the hashtable in the field map.
| alib::SharedLock dxl::Index::SLock |
A shared lock to this index. While most of the time (during link resolve) read-only access is needed, for a few operations a write-lock must be set. This is, for example, done in method tryResolveHTMLTargetFile, which modifies the index.
| int dxl::Index::StatCtdLines |
| dxl::Index::Index | ( | const alib::system::PathString & | tagFilePath, |
| const alib::String & | baseURL, | ||
| bool | isMainTagFile ) |
Constructor.
| tagFilePath | The path to the tag-file. |
| baseURL | The URL that the HTML files that this tag-files represent are found. |
| isMainTagFile | Sets field IsMainTagFile. |
|
inline |
After all source code and html files have been scanned, DoxygenXLinks continues single-threadded. By calling this method from Run, we can omit locks in the rest of the code without getting warnings. However, when option –doxyfy is given, we later enable them again.
| sWitch | Determines to enable or disable the checks. |
|
protected |
| void dxl::Index::DumpTree | ( | Index::Node | branch | ) |
Dumps the contents of the tag-file branch to the Lox.
| branch | The branch to dump. |
Definition at line 880 of file tagfile.cpp.
|
protected |
Sub-function by Search which checks various things, like function arguments, template parameters, etc, and applies internal disambiguation rules.
| xLink | The link that is processed. |
| node | The node to evaluate. |
| isIndirectByInheritance | Set if node is inherited member |
| isIndirectByTypeDef | Set if node is indirectly found through a type definiton. |
| Index::ConstCursorHandle dxl::Index::GetHTMLFileEntity | ( | const alib::File & | htmlFile | ) |
Returns the StringTree-node of the entity that is described in the given HTML file.
| htmlFile | The HTML file node. |
|
inline |
| void dxl::Index::Load | ( | ) |
|
protected |
Loads the tag-file. This is called by Load.
Definition at line 372 of file tagfile.cpp.
| void dxl::Index::ReplaceFromTreeSeparator | ( | alib::AString & | buffer, |
| Target::Kinds | kind, | ||
| alib::integer | startPos = 0 ) |
Replaces the tree separator with the character(s) appropriate for the given kind.
| buffer | The string buffer to modify. |
| kind | The kind of target for which the separator should be replaced. |
| startPos | The starting position within the buffer where the replacement should begin. Defaults to 0. |
| void dxl::Index::ReplaceToTreeSeparator | ( | alib::AString & | buffer, |
| Target::Kinds | kind, | ||
| alib::integer | startPos = 0 ) |
Replaces character(s) separating the scope of the given kind with the tree separator.
| buffer | The string buffer to modify. |
| kind | The kind of target for which the separator should be replaced. |
| startPos | The starting position within the buffer where the replacement should begin. Defaults to 0. |
| bool dxl::Index::ScopeHintMatch | ( | Index::Node | entry, |
| XLink & | searchLink ) |
Tests if the given node in the Index's StringTree sits in a path that matches the path hints of the given searchLink.
| entry | The node in the "dxl #Index" to test. |
| searchLink | The search definition to test against. |
true if the path ints given with this search specification are matching this the path to the entry | void dxl::Index::Search | ( | XLink & | xLink | ) |
Searches entries in this doxygen tag-file index. The given results vector might be filled already by other instances of this type in the case that multiple tag-files are provided with the doxygen INI-file. Also, a call to this function might insert more than one result.
| xLink | The link found in the HTML-files. |
|
protected |