Files
Sourcetrail/src/lib/utility/scheduling/TaskLambda.cpp
T
mlangkabel a1dd1a77c9 logic: allow the user to discard an aborted indexer run
* keep old database on filesystem while indexing
* migrate old ".coatiproject" settings to new ".srctrlprj" extension when loading project
* send new errors in MessageErrorCountUpdate after injecting
* recheck filepath exist() in FileSystem's remove, rename, copy and create functions
* updated tasks to new "override" policy
2018-07-03 18:54:53 +02:00

25 lines
440 B
C++

#include "utility/scheduling/TaskLambda.h"
TaskLambda::TaskLambda(std::function<void()> func)
: m_func(func)
{
}
void TaskLambda::doEnter(std::shared_ptr<Blackboard> blackboard)
{
}
Task::TaskState TaskLambda::doUpdate(std::shared_ptr<Blackboard> blackboard)
{
m_func();
return STATE_SUCCESS;
}
void TaskLambda::doExit(std::shared_ptr<Blackboard> blackboard)
{
}
void TaskLambda::doReset(std::shared_ptr<Blackboard> blackboard)
{
}