#include <client_loops_check.h>
◆ LoopsChecker()
apollo::hdmap::LoopsChecker::LoopsChecker |
( |
const std::string & |
time_flag_file | ) |
|
|
explicit |
在文件 client_loops_check.cc 第 28 行定义.
29 : time_flag_file_(time_flag_file) {
30 YAML::Node node = YAML::LoadFile(FLAGS_client_conf_yaml);
31 std::string server_addr =
32 node["grpc_host_port"]["grpc_host"].as<std::string>() + ":" +
33 node["grpc_host_port"]["grpc_port"].as<std::string>();
34 check_period_ = node["loops_check"]["check_period"].as<int>();
35 service_stub_ = CollectionCheckerService::NewStub(
36 grpc::CreateChannel(server_addr, grpc::InsecureChannelCredentials()));
37}
◆ SyncStart()
int apollo::hdmap::LoopsChecker::SyncStart |
( |
bool * |
reached | ) |
|
在文件 client_loops_check.cc 第 39 行定义.
39 {
40 std::vector<std::pair<double, double>> time_ranges = GetTimeRanges();
41 size_t pair_count = time_ranges.size();
42 if (pair_count == 0) {
43 AINFO <<
"there is no time range";
44 return -1;
45 }
46 int ret = Start(time_ranges);
47 if (ret != 0) {
48 AINFO <<
"loops check start failed";
50 return -1;
51 }
52 return PeriodicCheck(reached);
53}
该类的文档由以下文件生成: