Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef CARTOGRAPHER_MAPPING_INTERNAL_WORK_QUEUE_H
00018 #define CARTOGRAPHER_MAPPING_INTERNAL_WORK_QUEUE_H
00019
00020 #include <chrono>
00021 #include <deque>
00022 #include <functional>
00023
00024 namespace cartographer {
00025 namespace mapping {
00026
00027 struct WorkItem {
00028 enum class Result {
00029 kDoNotRunOptimization,
00030 kRunOptimization,
00031 };
00032
00033 std::chrono::steady_clock::time_point time;
00034 std::function<Result()> task;
00035 };
00036
00037 using WorkQueue = std::deque<WorkItem>;
00038
00039 }
00040 }
00041
00042 #endif // CARTOGRAPHER_MAPPING_INTERNAL_WORK_QUEUE_H