Brad Bishop | f3df6b4 | 2017-01-06 10:14:09 -0500 | [diff] [blame] | 1 | #pragma once |
| 2 | |
| 3 | class SensorSet; |
| 4 | |
| 5 | std::string getEnv( |
| 6 | const char* prefix, const SensorSet::key_type& sensor); |
Tom Joseph | 1f8a958 | 2017-06-12 20:10:59 +0530 | [diff] [blame] | 7 | |
| 8 | /** @brief Get the label for the sensor with a level of indirection. |
| 9 | * |
| 10 | * Read the sensor number from the <path>/<item><X>_label file.<item> & <X> is |
| 11 | * populated from the sensor key. The sensor label is read from the environment |
| 12 | * variable <prefix>_<item><sensorNum>. |
| 13 | * |
| 14 | * @param[in] prefix - Prefix of the environment variable. |
| 15 | * @param[in] path - Directory path of the label file. |
| 16 | * @param[in] sensor - Sensor details. |
| 17 | * |
| 18 | * @return On success return the sensor label, in case of failure return empty |
| 19 | * string. |
| 20 | */ |
| 21 | std::string getIndirectLabelEnv( |
| 22 | const char* prefix, std::string path, const SensorSet::key_type& sensor); |