scenario_simulator_v2 C++ API
job_list.hpp
Go to the documentation of this file.
1 // Copyright 2015 TIER IV, Inc. All rights reserved.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 
15 #ifndef TRAFFIC_SIMULATOR__JOB__JOB_LIST_HPP_
16 #define TRAFFIC_SIMULATOR__JOB__JOB_LIST_HPP_
17 
19 #include <vector>
20 
21 namespace traffic_simulator
22 {
23 namespace job
24 {
25 class JobList
26 {
27 public:
28  void append(
29  const std::function<bool(const double)> & func_on_update,
30  const std::function<void()> & func_on_cleanup, job::Type type, bool exclusive,
31  const job::Event event);
32  void update(const double step_time, const job::Event event);
33 
34 private:
35  std::vector<Job> list_;
36 };
37 } // namespace job
38 } // namespace traffic_simulator
39 
40 #endif // TRAFFIC_SIMULATOR__JOB__JOB_LIST_HPP_
Definition: job_list.hpp:26
void update(const double step_time, const job::Event event)
Definition: job_list.cpp:34
void append(const std::function< bool(const double)> &func_on_update, const std::function< void()> &func_on_cleanup, job::Type type, bool exclusive, const job::Event event)
Definition: job_list.cpp:22
Event
Definition: job.hpp:39
Type
Definition: job.hpp:25
Definition: api.hpp:49