123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320 |
- #ifndef _SERVER_CONST_DEF_H_
- #define _SERVER_CONST_DEF_H_
- #define MAXCRITICALSECTIONSPINCOUNT 4000
- #define INTERFACE_VERSION "1.0.0.2"
- #define INTERFACE_VERSION_1_3 "1.0.0.3"
- #define INTERFACE_VERSION_1_4 "1.0.0.4"
- #define TEST_WEB_URL "http://localhost:8080/yaloc/servlet/main?"
- //#define TEST_WS_URL "ws://localhost:8086"
- //#define TEST_WS_URL "ws://192.168.0.36:8086"
- #define TEST_WS_URL "ws://182.92.224.191:8086"
- #define TEST_CONFIRM_COUNT 1
- #define PARAM_NAME_USERNAME "username"
- #define PARAM_NAME_INTERFACE "interface"
- #define PARAM_NAME_DATA "data"
- #define PARAM_NAME_VERSION "version"
- #define JSON_ROOT_KEY_CMD "cmd"
- #define JSON_ROOT_KEY_VERSION "version"
- #define JSON_ROOT_KEY_DATA "data"
- #define JSON_ROOT_KEY_DIFF_TICK_COUNT "difftick"
- #define JSON_ROOT_KEY_TOTAL "total"
- #define JSON_ROOT_KEY_STATISTIC_VEHICLE_DATA "v"
- #define JSON_ROOT_KEY_STATISTIC_STAFF_DATA "s"
- #define JSON_ROOT_KEY_STATISTIC_STAT "stat"
- #define JSON_ROOT_KEY_STATISTIC_DETAIL "detail"
- #define JSON_ROOT_KEY_STATISTIC_GLOBAL "glbl"
- #define JSON_ROOT_KEY_STATISTIC_DEPT "dept"
- #define JSON_ROOT_KEY_STATISTIC_SUM "sum"
- #define JSON_ROOT_KEY_STATISTIC_AREA "area"
- #define JSON_ROOT_KEY_STATISTIC_AREA_ID "area_id"
- #define JSON_ROOT_KEY_STATISTIC_DEPT_ID "dept_id"
- #define JSON_ROOT_KEY_STATISTIC_LEVEL "occupation_level"
- #define JSON_ROOT_KEY_STATISTIC_LEVEL_ID "level_id"
- // 采集端接收接口
- #define JSON_CMD_VALUE_SET_LIMIT_VALUE "set_limit_value"
- #define JSON_CMD_VALUE_CALL_CARD "call_card"
- #define JSON_CMD_VALUE_CLEAR_CARD "clear_card"
- #define JSON_CMD_VALUE_DEAL_HELP "helpme_done" //deal_help
- #define JSON_CMD_VALUE_EDIT_MAP "edit_map"
- #define JSON_CMD_VALUE_EDIT_AREA "edit_area"
- #define JSON_CMD_VALUE_EDIT_STATION "edit_station"
- #define JSON_CMD_VALUE_EDIT_PATH "edit_path"
- #define JSON_CMD_VALUE_EDIT_CARD "edit_card"
- #define JSON_CMD_VALUE_EDIT_STAFFER "edit_staffer"
- #define JSON_CMD_VALUE_EDIT_VEHICLE "edit_vehicle"
- #define JSON_CMD_VALUE_REQUEST_ALL_POSTION "request_all_postion"
- #define JSON_CMD_VALUE_SET_LIGHT_COLOR "set_light_color"
- #define JSON_CMD_VALUE_REQUEST_ALL_DATA "req_all_data"
- #define JSON_CMD_VALUE_RESPONSE_ALL_DATA "resp_all_data"
- #define JSON_CMD_VALUE_CALL_CARD_START "call_card_start"
- #define JSON_CMD_VALUE_CALL_CARD_CANCEL "call_card_cancel"
- //呼叫命令
- #define JSON_CMD_VALUE_CALL_CARD_REQUEST "call_card_req"
- #define JSON_CMD_VALUE_CALL_CARD_RESPONSE "call_card_resp"
- #define JSON_CMD_VALUE_CALL_CARD_CANCEL_REQUEST "call_card_cancel_req"
- #define JSON_CMD_VALUE_CALL_CARD_CANCEL_RESPONSE "call_card_cancel_resp"
- #define JSON_CMD_VALUE_CALL_CARD_LIST "callcardlist"
- #define JSON_CMD_VALUE_META_DATA_CHANGED "meta_data_changed"
- #define JSON_CMD_VALUE_LIGHTS_CTRL_REQUEST "lights_ctrl_req"
- #define JSON_CMD_VALUE_LIGHTS_CTRL_RESPONSE "lights_ctrl_res"
- #define JSON_KEY_NAME "name"
- #define JSON_KEY_ID "id"
- #define JSON_KEY_OP_TYPE "op_type"
- #define JSON_KEY_NAME_MAP "map"
- #define JSON_KEY_NAME_AREA "area"
- #define JSON_KEY_NAME_PATH "path"
- #define JSON_KEY_NAME_READER "reader"
- #define JSON_KEY_NAME_CARD "card"
- #define JSON_KEY_NAME_STAFF "staff"
- #define JSON_KEY_NAME_VEHICLE "vehicle"
- #define JSON_KEY_NAME_SECTION "section"
- #define JSON_KEY_NAME_LIGHT "light"
- #define JSON_KEY_NAME_CHAMBER "chamber"
- #define JSON_KEY_NAME_SHIFT "shift"
- #define JSON_KEY_NAME_PATROL_TASK "patrol_task"
- #define JSON_KEY_OP_TYPE_INSERT "INSERT"
- #define JSON_KEY_OP_TYPE_UPDATE "UPDATE"
- #define JSON_KEY_OP_TYPE_DELETE "DELETE"
- #define JSON_KEY_CALL_CARD_CALL_ID "call_id"
- #define JSON_KEY_CALL_CARD_CALL_TIME_OUT "call_time_out"
- #define JSON_KEY_CALL_CARD_CALL_TIME "call_time"
- #define JSON_KEY_CALL_CARD_CALL_TYPE "call_type_id"
- #define JSON_KEY_CALL_CARD_USER_NAME "user_name"
- #define JSON_KEY_CALL_CARD_CALL_TIME "call_time"
- #define JSON_KEY_CALL_CARD_STATIONS "stations"
- #define JSON_KEY_CALL_CARD_STATION_ID "stationid"
- #define JSON_KEY_CALL_CARD_CARDS "cards"
- #define JSON_KEY_CALL_CARD_CARD_ID "cardid"
- #define JSON_KEY_CALL_CARD_CARD_TYPE_ID "cardtype"
- #define JSON_KEY_CALL_LIGHT_TASK_ID "task_id"
- #define JSON_KEY_CALL_LIGHT_OBJ_TYPE "obj_type"
- #define JSON_KEY_CALL_LIGHT_CTRL_TYPE "ctrl_type"
- #define JSON_KEY_CALL_LIGHT_LIGHT_STATE "light_state"
- #define JSON_KEY_CALL_LIGHT_USER_ID "user_id"
- #define JSON_KEY_CALL_LIGHT_LIGHTS "lights"
- #define JSON_KEY_CALL_LIGHT_ID "id"
- #define JSON_KEY_EDIT_MAP_ID "map_id"
- #define JSON_KEY_EDIT_AREA_ID "areaid"
- #define JSON_KEY_EDIT_READER_ID "stationid"
- #define JSON_KEY_EDIT_CARD_ID "cardid"
- #define JSON_KEY_EDIT_CARD_TYPE "cardtype"
- #define JSON_KEY_EDIT_STAFFER_ID "stafferid"
- #define JSON_KEY_EDIT_VEHICLE_ID "vehicleid"
- #define JSON_KEY_EDIT_EDIT_TYPE_ID "edittype"
- // 采集端调用接口
- #define JSON_CMD_VALUE_LOGIN "login"
- #define JSON_CMD_VALUE_LOGOUT "logout"
- #define JSON_KEY_USERNAME "user_name"
- #define JSON_KEY_PASSWORD "user_pass"
- #define JSON_VALUE_USERNAME "COLLECTOR"
- #define JSON_VALUE_PASSWORD "666666" //"666666"
- //#define JSON_VALUE_USERNAME "lihz"
- //#define JSON_VALUE_PASSWORD "000"
- //#define JSON_KEY_VEHICLE_ID "编号"
- //#define JSON_KEY_VEHICLE_TYPE "车辆类型"
- //#define JSON_KEY_VEHICLE_DEPT "部门"
- //#define JSON_KEY_VEHICLE_NO "车牌号"
- #define JSON_KEY_CARD_ID "card_id" //"卡号"
- #define JSON_KEY_CARD_TYPE_ID "card_type_id"
- #define JSON_KEY_CARD_NUM "number" //"编号"
- #define JSON_KEY_CARD_NAME "name" // "名称"
- #define JSON_KEY_CARD_WORKTYPE "work_type" // "类型"
- #define JSON_KEY_CARD_COMP "company" // "单位"
- #define JSON_KEY_CARD_DEPT "dept" // "部门"
- #define JSON_KEY_REC_TIME "rec_time" // "接收时间"
- #define JSON_KEY_DOWN_TIME "down_time" // "入井时间"
- #define JSON_KEY_UP_TIME "up_time" // "升井时间"
- #define JSON_KEY_ENTER_PARK_TIME "enter_park_time" // "回场时间"
- #define JSON_KEY_LEAVE_PARK_TIME "leave_park_time" // "出场时间"
- #define JSON_KEY_WORK_TIME "work_time" // "工作时间"
- #define JSON_KEY_ENTER_AREA_TIME "enter_area_time" // "进入区域时间"
- #define JSON_KEY_ENTER_READER_TIME "enter_reader_time" // "进入分站时间"
- #define JSON_KEY_CORDINATE_X "x"
- #define JSON_KEY_CORDINATE_Y "y"
- #define JSON_KEY_CORDINATE_Z "z"
- #define JSON_KEY_STATE "state" // "状态"
- #define JSON_KEY_STATE_DESC "state_desc" // "状态"
- #define JSON_KEY_STATE_MOVING "state_moving" // 运动状态
- #define JSON_KEY_STATE_BIZ "state_biz" // 业务状态
- #define JSON_KEY_ANGLE "angle" // "角度"
- #define JSON_KEY_MAP_ID "map_id" // "地图编号"
- #define JSON_KEY_MAP_NAME "map_name" // "地图名称"
- #define JSON_KEY_MAP_PATH "map_path" // "地图路径"
- #define JSON_KEY_MAP_HEIGHT "map_height" // "地图高度"
- #define JSON_KEY_MAP_WIDTH "map_width" // "地图宽度"
- #define JSON_KEY_MAP_SCALE "map_scale" // "地图比例"
- #define JSON_KEY_MAP_TYPE "map_type" // "地图类型"
- #define JSON_KEY_DEPT_ID "dept_id"
- #define JSON_KEY_SPEED "speed" //速度
- #define JSON_KEY_LANDMARK_ID "landmark_id"
- #define JSON_KEY_DIRECTORY_ID "landmark_direction_id"
- #define JSON_KEY_LANDMARK_DIS "landmark_distance"
- // id, name, type, map_id
- #define JSON_KEY_AREA_ID "area_id" // "区域编号"
- #define JSON_KEY_AREA_TYPE "area_type" // "区域类型"
- #define JSON_KEY_AREA_NAME "area_name" // "区域名称"
- #define JSON_KEY_AREA_IS_SPECIAL "is_special_area" // "区域名称"
- #define JSON_KEY_AREA_X "area_x" // "区域坐标"
- #define JSON_KEY_AREA_Y "area_y" //
- #define JSON_KEY_AREA_Z "area_z" //
- #define JSON_KEY_AREA_R "area_radius" // "区域半径"
- // id, name, angle, x, y, z, type, map_id, area_id
- #define JSON_KEY_READER_ID "reader_id" // "分站编号"
- #define JSON_KEY_READER_NAME "reader_name" // "分站名称"
- #define JSON_KEY_READER_POS_STATE "reader_type" // "分站类型"
- #define JSON_KEY_READER_STATE "reader_state" // "分站状态"
- #define JSON_KEY_ANTENNA_ID "ant_id" // "天线编号"
- #define JSON_KEY_ANTENNA_NAME "ant_name" // "天线名称"
- #define JSON_KEY_DEV_MAP "dev_map"
- #define JSON_KEY_DEV_AREA "dev_area"
- #define JSON_KEY_DEV_READER "dev_reader"
- #define JSON_KEY_DEV_CARD "dev_card"
- #define JSON_KEY_DEV_TRAFFIC "dev_traffic"
- #define JSON_KEY_DEV_TURNOUT "dev_turnout"
- #define JSON_KEY_DEV_LOUDSPEEKER "dev_loudspeeker"
- // down_mine,up_mine
- #define JSON_CMD_VALUE_DOWN_MINE "down_mine"
- #define JSON_CMD_VALUE_UP_MINE "up_mine"
- #define JSON_CMD_VALUE_SPECIAL_AREA_UP_MINE "special_area_up_mine"
- #define JSON_CMD_VALUE_COUNTING "counting"
- #define JSON_CMD_VALUE_DEV_STATE "device_state"
- #define JSON_CMD_VALUE_ALARM "alarm"
- #define JSON_CMD_VALUE_EVENT "event"
- #define JSON_CMD_VALUE_CALL "CALL"
- #define JSON_CMD_VALUE_PUSH "PUSH"
- #define JSON_CMD_VALUE_USER "USER" //"USER"
- #define JSON_CMD_VALUE_WS_ERR "WS_ERR"
- #define JSON_CMD_DRIVING_FACE_STATE "tunneller_stat"
- // pos_map
- #define JSON_CMD_VALUE_POS_MAP "pos_map"
- #define JSON_CMD_VALUE_POSITION_ALL "position_all"
- #define JSON_CMD_VALUE_STATISTIC "postition_statistic"
- #define JSON_KEY_POS_CARD "pos_card"
- #define JSON_KEY_POS_MAP "pos_map"
- // device state, stat_map
- #define JSON_KEY_DEV_STATE_MAP_ID "map_id"
- #define JSON_KEY_DEV_STATE_DEVICES "devices"
- #define JSON_KEY_DEV_STATE_DEVICE_ID "device_id"
- #define JSON_KEY_DEV_STATE_STATE "state"
- #define JSON_KEY_DEV_STATE_STATE_DESC "state_desc"
- #define JSON_KEY_DEV_STATE_DEVICE_TYPE_ID "device_type_id"
- #define JSON_KEY_DEV_STATE_TIME "time"
- //#define JSON_KEY_STAT_MAP_STAT_TRAFFIC "stat_traffic"
- //#define JSON_KEY_STAT_MAP_STAT_TURNOUT "stat_turnout"
- //#define JSON_KEY_STAT_MAP_STAT_LOUDSPEEKER "stat_loudspeeker"
- // counting
- #define JSON_KEY_COUNTING_COUNT_TOTAL "total" // 总卡数
- #define JSON_KEY_COUNTING_COUNT_VEHICLE "vehicle" // 总车数
- #define JSON_KEY_COUNTING_COUNT_PERSON "staff" // 总人数
- #define JSON_KEY_COUNTING_MAP_COUNT "maps"
- #define JSON_KEY_COUNTING_MAP_ID "id"
- #define JSON_KEY_COUNTING_MAP_COUNT_TOTAL "total" // 当前图中总数
- #define JSON_KEY_COUNTING_MAP_COUNT_PERSON "staff" // "map_count_vehicle" // 当前图车数
- #define JSON_KEY_COUNTING_MAP_COUNT_VEHICLE "vehicle"// "map_count_person" // 当前图车数
- #define JSON_KEY_COUNTING_AREA_COUNT "areas"
- #define JSON_KEY_COUNTING_AREA_ID "id"
- #define JSON_KEY_COUNTING_AREA_COUNT_TOTAL "total" // 区域总卡数
- #define JSON_KEY_COUNTING_AREA_COUNT_PERSON "staff" // 区域人数
- #define JSON_KEY_COUNTING_AREA_COUNT_VEHICLE "vehicle" // 区域车数
- #define JSON_KEY_COUNTING_DEPT_COUNT "depts"
- #define JSON_KEY_COUNTING_DEPT_ID "id"
- //#define JSON_KEY_COUNTING_DEPT_NAME "dept_name"
- #define JSON_KEY_COUNTING_AREA_PERSON_COUNT "area_person"
- #define JSON_KEY_COUNTING_DEPT_COUNT_TOTAL "total"
- #define JSON_KEY_COUNTING_DEPT_COUNT_VEHICLE "vehicle"
- #define JSON_KEY_COUNTING_DEPT_COUNT_PERSON "staff"
- #define JSON_KEY_COUNTING_SPECIAL_ERROR_TOTAL "special_error_total"
- #define JSON_KEY_REQ_COUNTS_USER "req_user"
- #define JSON_KEY_REQ_COUNTS_TYPE "count_type"
- #define JSON_KEY_REQ_COUNTS_TIME "req_time"
- // #define JSON_CMD_VALUE_REQUEST_COUNTS_INFO "count_detail_req" //web端请求统计总数详细列表
- // #define JSON_KEY_RESPONSE_COUNTS_DETAIL "count_detail_resp"
- #define JSON_KEY_EVENT_EVENT_ID "event_id"
- #define JSON_KEY_EVENT_STATUS "status"
- #define JSON_KEY_EVENT_TYPE_ID "type_id"
- #define JSON_KEY_EVENT_OBJ_TYPE_ID "obj_type_id"
- #define JSON_KEY_EVENT_OBJ_ID "obj_id"
- #define JSON_KEY_EVENT_MAP_ID "map_id"
- #define JSON_KEY_EVENT_AREA_ID "area_id"
- #define JSON_KEY_EVENT_X "x"
- #define JSON_KEY_EVENT_Y "y"
- #define JSON_KEY_EVENT_LIMIT_VALUE "limit_value"
- #define JSON_KEY_EVENT_CUR_VALUE "cur_value"
- #define JSON_KEY_EVENT_CUR_TIME "cur_time"
- #define JSON_KEY_EVENT_LANDMARK_ID "lmid"
- #define JSON_KEY_EVENT_LANDMARK_DIRECTION "lmdirect"
- #define JSON_KEY_EVENT_LANDMARK_DISTANCE "lmdistance"
- #define JSON_CMD_VALUE_REQUEST_COUNTS_INFO "count_detail_req" //web端请求统计总数详细列表
- #define JSON_KEY_RESPONSE_COUNTS_DETAIL "count_detail_resp"
- #define JSON_KEY_EVENT_READER_POS_CHANGE "reader_pos_change"
- // alarm
- #define JSON_KEY_ALARM_OVER_COUNT_PERSON "over_count_person"
- #define JSON_KEY_ALARM_OVER_COUNT_VEHICLE "over_count_vehicle"
- #define JSON_KEY_ALARM_OVER_TIME_PERSON "over_time_person"
- #define JSON_KEY_ALARM_OVER_TIME_VEHICLE "over_time_vehicle"
- #define JSON_KEY_ALARM_OVER_SPEED_VEHICLE "over_speed_vehicle"
- #define JSON_KEY_ALARM_AREA_FORBIDDEN "area_forbidden"
- #define JSON_KEY_ALARM_AREA_OVER_TIME_PERSON "area_over_time_person"
- #define JSON_KEY_ALARM_AREA_OVER_TIME_VEHICLE "area_over_time_vehicle"
- #define JSON_KEY_ALARM_AREA_OVER_PERSON "area_over_person"
- #define JSON_KEY_ALARM_AREA_OVER_VEHICLE "area_over_vehicle"
- #define JSON_KEY_ALARM_GLOBAL "global"
- #define JSON_KEY_ALARM_ITEM "item"
- #define JSON_KEY_ALARM_DETAIL "detail"
- #define JSON_KEY_ALARM_MAX "max"
- #define JSON_KEY_ALARM_CURRENT "current"
- #define JSON_KEY_ALARM_AREA "areas"
- #define JSON_KEY_ALARM_AREA_ID "area_id"
- #define JSON_KEY_ALARM_ALARMS "alarms"
- #define JSON_KEY_ALARM_PERSON "person"
- #define JSON_KEY_ALARM_VEHICLE "vehicle"
- #define JSON_KEY_ALARM_ADHOC "adhoc"
- #define JSON_KEY_ALARM_READER "readers"
- #define JSON_KEY_ALARM_READER_ID "reader_id"
- #define JSON_KEY_ALARM_TYPE_ID "alarm_type_id"
- #define JSON_KEY_ALARM_TYPE_NAME "alarm_type_name"
- #define JSON_KEY_ALARM_START_TIME "alarm_start_time"
- #define JSON_KEY_ALARM_STAFF "staff"
- #define JSON_KEY_ALARM_STAFFER_ID "staffer_id"
- #define JSON_KEY_ALARM_VEHICLE_ID "vehicle_id"
- #define JSON_KEY_ALARM_SECTION "section_info"
- #define JSON_KEY_ALARM_SECTION_ID "section_id"
- #define JSON_KEY_ALARM_SECTION_VEHICLE_COUNTS "vehicle_counts"
- #define JSON_KEY_ALARM_SECTION_STAFFER_COUNTS "staffer_counts"
- #define JSON_KEY_ALARM_SECTION_STATE "state"
- #define JSON_KEY_ALARM_LIGHT "light_info"
- #define JSON_KEY_ALARM_LIGHT_ID "light_id"
- #define JSON_KEY_ALARM_LIGHT_GROUP_ID "light_group_id"
- #define JSON_KEY_ALARM_LIGHT_GROUP_NAME "light_group_name"
- #define JSON_KEY_ALARM_TRAFFIC_RED_LIGHT "traffic_red_light"
- #define JSON_KEY_DRIVINGFACE_DIS "driving_face_moving_dis"
- #define JSON_KEY_DRIVINGFACE_WARNING_POINT_ID "driving_face_warning_point_id"
- #define JSON_KEY_DRIVINGFACE_WARNING_POINT_DIS "driving_face_warning_point_dis"
- #endif // !_SERVER_CONST_DEF_H_
|