This change adds graph data structures Token, Node, Edge and Graph for holding code semantics in the Storage and fills them with the parsed data. Things to note: * Token is the base for the classes Edge and Node and holds a unique id. * Graph is the owner of all Nodes and Edges. * A Node saves the Edges it is endpoint of. * An Edge saves the Nodes that are endpoints. * Nodes and Edges are not subclassed. The different Node and Edge types are distinguished by the enums NodeType and EdgeType. Type specific fields are therefore available for all types, a check when assigning them prohibits faulty usage. * Storage uses the Graph::getNodeHierarchy method, which is not strict about knowing type names beforehand. E.g. if A::B is passed in and A doesn't exist so far, then node A gets created as NODE_UNDEFINED with B as it's child. * The Graph methods addNodeAsPlainCopy and addEdgeAsPlainCopy can be used to create a sub-graph without reference to the original, but with the same ids. review id = 19 fortune cookie message = Your cheerful outlook is one of your best assets.
17 lines
302 B
CMake
17 lines
302 B
CMake
add_files(
|
|
TEST_FILES
|
|
|
|
ConfigManagerTestSuite.h
|
|
CxxParserTestSuite.h
|
|
FileSystemTestSuite.h
|
|
GraphTestSuite.h
|
|
LogManagerTestSuite.h
|
|
MessageQueueTestSuite.h
|
|
ProjectSettingsTestSuite.h
|
|
TestSuiteFixture.cpp
|
|
TestSuiteFixture.h
|
|
TextAccessTestSuite.h
|
|
UtilityStringTestSuite.h
|
|
Vector2TestSuite.h
|
|
)
|