logic: Fixed bugs in TaskParse scheduling

* Added TaskParse as base for TaskParseCxx and TaskParseJava
* Fixed increment and decrement of indexer_count on blackboard not atomic
* Fixed TaskInjectStorage finished before TaskParse started
* Fixed project not cleared when refreshing on now empty project
* Fixed TaskInjectStorage overheating when nothing to do
This commit is contained in:
Eberhard Graether
2016-10-20 23:02:54 +02:00
parent a388932864
commit 06c7a4e159
12 changed files with 147 additions and 128 deletions
@@ -13,6 +13,11 @@ Blackboard::~Blackboard()
{
}
std::mutex& Blackboard::getMutex()
{
return m_mutex;
}
bool Blackboard::exists(const std::string& key)
{
std::lock_guard<std::mutex> lock(m_itemMutex);
+4
View File
@@ -37,6 +37,8 @@ public:
Blackboard(std::shared_ptr<Blackboard> parent);
~Blackboard();
std::mutex& getMutex();
template <typename T>
void set(const std::string& key, const T& value);
@@ -51,6 +53,8 @@ private:
std::shared_ptr<Blackboard> m_parent;
std::mutex m_mutex;
ItemMap m_items;
std::mutex m_itemMutex;
};