Eventqueue: Remove unused code

This commit is contained in:
Michael Friedrich 2019-04-25 16:21:07 +02:00
parent e86e3cc234
commit a7873da89d
2 changed files with 0 additions and 21 deletions

View File

@ -90,25 +90,6 @@ void EventQueue::SetFilter(std::unique_ptr<Expression> filter)
m_Filter.swap(filter);
}
Dictionary::Ptr EventQueue::WaitForEvent(void *client, double timeout)
{
boost::mutex::scoped_lock lock(m_Mutex);
for (;;) {
auto it = m_Events.find(client);
ASSERT(it != m_Events.end());
if (!it->second.empty()) {
Dictionary::Ptr result = *it->second.begin();
it->second.pop_front();
return result;
}
if (!m_CV.timed_wait(lock, boost::posix_time::milliseconds(long(timeout * 1000))))
return nullptr;
}
}
std::vector<EventQueue::Ptr> EventQueue::GetQueuesForType(const String& type)
{
EventQueueRegistry::ItemMap queues = EventQueueRegistry::GetInstance()->GetItems();

View File

@ -36,8 +36,6 @@ public:
void SetTypes(const std::set<String>& types);
void SetFilter(std::unique_ptr<Expression> filter);
Dictionary::Ptr WaitForEvent(void *client, double timeout = 5);
static std::vector<EventQueue::Ptr> GetQueuesForType(const String& type);
static void UnregisterIfUnused(const String& name, const EventQueue::Ptr& queue);