src: code cleanup

* removed unused code: ParseFunction, ParseVariable and ParseTypeUsage. All this is handled using NameHierarchies now.
* Moved the getErrorCount method from ParserClient to the StorageAccess
* MessageFinishedParsing doesn't know the error count anymore.
* StatusBarController now has a StorageAccess to fetch the error count when needed.
This commit is contained in:
malte_langkabel
2016-03-07 10:59:39 +01:00
parent 5cdaafc6de
commit 6d7a1faaa4
25 changed files with 121 additions and 590 deletions
+2
View File
@@ -10,6 +10,7 @@
#include "data/graph/Node.h"
#include "data/search/SearchMatch.h"
#include "data/ErrorCountInfo.h"
#include "data/StorageStats.h"
struct FileInfo;
@@ -62,6 +63,7 @@ public:
virtual std::shared_ptr<TextAccess> getFileContent(const FilePath& filePath) const = 0;
virtual TimePoint getFileModificationTime(const FilePath& filePath) const = 0;
virtual ErrorCountInfo getErrorCount() const = 0;
virtual StorageStats getStorageStats() const = 0;
};
@@ -275,6 +275,16 @@ TimePoint StorageAccessProxy::getFileModificationTime(const FilePath& filePath)
return TimePoint(boost::posix_time::not_a_date_time);
}
ErrorCountInfo StorageAccessProxy::getErrorCount() const
{
if (hasSubject())
{
return m_subject->getErrorCount();
}
return ErrorCountInfo();
}
StorageStats StorageAccessProxy::getStorageStats() const
{
if (hasSubject())
+1
View File
@@ -51,6 +51,7 @@ public:
virtual std::shared_ptr<TextAccess> getFileContent(const FilePath& filePath) const;
virtual TimePoint getFileModificationTime(const FilePath& filePath) const;
virtual ErrorCountInfo getErrorCount() const;
virtual StorageStats getStorageStats() const;
private: