Lines Matching refs:key
66 static bool CopyInt32Array(const char *key, in CopyInt32Array() argument
69 if (json->getArray(key, &array)) { in CopyInt32Array()
81 static bool CopyFloatArray(const char *key, in CopyFloatArray() argument
84 if (json->getArray(key, &array)) { in CopyFloatArray()
96 static bool GetCalibrationBytes(const char *key, SensorType sensor_type, in GetCalibrationBytes() argument
108 success = CopyInt32Array(key, json, bytes); in GetCalibrationBytes()
112 success = CopyFloatArray(key, json, bytes); in GetCalibrationBytes()
118 success = json->getFloat(key, &value); in GetCalibrationBytes()
128 success = CopyInt32Array(key, json, bytes); in GetCalibrationBytes()
131 success = json->getInt32(key, &value); in GetCalibrationBytes()
290 std::string key; in LoadCalibration() local
293 std::tie(key, sensor_type) = kCalibrationKeys[i]; in LoadCalibration()
294 if (GetCalibrationBytes(key.c_str(), sensor_type, cal_data)) { in LoadCalibration()
309 const char *key = AndroidContextHub::SensorTypeToCalibrationKey(sensor_type); in SetCalibration() local
310 if (cal_file && key) { in SetCalibration()
311 return cal_file->SetSingleAxis(key, data); in SetCalibration()
321 const char *key = AndroidContextHub::SensorTypeToCalibrationKey(sensor_type); in SetCalibration() local
322 if (cal_file && key) { in SetCalibration()
323 return cal_file->SetSingleAxis(key, data); in SetCalibration()
333 const char *key = AndroidContextHub::SensorTypeToCalibrationKey(sensor_type); in SetCalibration() local
334 if (cal_file && key) { in SetCalibration()
335 return cal_file->SetTripleAxis(key, x, y, z); in SetCalibration()
345 const char *key = AndroidContextHub::SensorTypeToCalibrationKey(sensor_type); in SetCalibration() local
346 if (cal_file && key) { in SetCalibration()
347 return cal_file->SetFourAxis(key, x, y, z, w); in SetCalibration()
405 const char *key; in SensorTypeToCalibrationKey() local
408 std::tie(key, sensor_type_for_key) = kCalibrationKeys[i]; in SensorTypeToCalibrationKey()
410 return key; in SensorTypeToCalibrationKey()