logic: removed namespace splitting from GraphController

Namespace splitting is now handled in active token id retrieval from the Storage, so that namespace nodes are not added
to the Graph at all and complexity in the GraphController is reduced.
This commit is contained in:
Eberhard Graether
2015-09-24 15:37:35 +02:00
parent 97e49d9b3f
commit b8c95c5a20
13 changed files with 107 additions and 86 deletions
+13 -3
View File
@@ -103,6 +103,16 @@ std::shared_ptr<Graph> StorageAccessProxy::getGraphForActiveTokenIds(const std::
return std::make_shared<Graph>();
}
std::vector<Id> StorageAccessProxy::getActiveTokenIdsForTokenIds(const std::vector<Id>& tokenIds) const
{
if (hasSubject())
{
return m_subject->getActiveTokenIdsForTokenIds(tokenIds);
}
return std::vector<Id>();
}
std::vector<Id> StorageAccessProxy::getActiveTokenIdsForId(Id tokenId, Id* delcarationId) const
{
if (hasSubject())
@@ -113,14 +123,14 @@ std::vector<Id> StorageAccessProxy::getActiveTokenIdsForId(Id tokenId, Id* delca
return std::vector<Id>();
}
Id StorageAccessProxy::getActiveNodeIdForLocationId(Id locationId) const
std::vector<Id> StorageAccessProxy::getNodeIdsForLocationIds(const std::vector<Id>& locationIds) const
{
if (hasSubject())
{
return m_subject->getActiveNodeIdForLocationId(locationId);
return m_subject->getNodeIdsForLocationIds(locationIds);
}
return 0;
return std::vector<Id>();
}
std::vector<Id> StorageAccessProxy::getTokenIdsForMatches(const std::vector<SearchMatch>& matches) const