| | |
| | | #include <stdio.h> |
| | | |
| | | #include <map> |
| | | #include <memory> |
| | | #include <string> |
| | | #include <thread> |
| | |
| | | // } |
| | | |
| | | // 时间规则 |
| | | std::vector<protomsg::CameraTimerule> list; |
| | | if (dbapi_get_time_rules(handle, list)) { |
| | | // std::vector<protomsg::CameraTimerule> list; |
| | | // if (dbapi_get_time_rules(handle, list)) { |
| | | // for (unsigned int i = 0; i < list.size(); i++) { |
| | | // printf("CameraTimerule: %s\n", list[i].id().c_str()); |
| | | // } |
| | | // } |
| | | |
| | | // 系统授权信息 |
| | | // printf("isExpired:%d\n", dbapi_get_server_get_is_sys_expired(handle)); |
| | | |
| | | // 摄像机 |
| | | std::vector<protomsg::Camera> list; |
| | | char *runType = (char *)"1"; // 1 实时 0 轮询 |
| | | if (dbapi_get_cameras_by_runType(handle, list, runType, false)) { |
| | | for (unsigned int i = 0; i < list.size(); i++) { |
| | | printf("CameraTimerule: %s\n", list[i].id().c_str()); |
| | | printf("Camera: %s\n", list[i].id().c_str()); |
| | | } |
| | | } |
| | | |
| | | //系统授权信息 |
| | | printf("isExpired:%d\n", dbapi_get_server_get_is_sys_expired(handle)); |
| | | |
| | | return 0; |
| | | } |