|
ESPHome 2025.10.4
|
#include <entity_base.h>
Public Member Functions | |
| std::string | get_unit_of_measurement () |
| Get the unit of measurement, using the manual override if set. | |
| void | set_unit_of_measurement (const char *unit_of_measurement) |
| Manually set the unit of measurement. | |
| StringRef | get_unit_of_measurement_ref () const |
| Get the unit of measurement as StringRef. | |
Protected Attributes | |
| const char * | unit_of_measurement_ {nullptr} |
| Unit of measurement override. | |
Definition at line 169 of file entity_base.h.
| std::string esphome::EntityBase_UnitOfMeasurement::get_unit_of_measurement | ( | ) |
Get the unit of measurement, using the manual override if set.
Definition at line 94 of file entity_base.cpp.
|
inline |
Get the unit of measurement as StringRef.
Definition at line 176 of file entity_base.h.
| void esphome::EntityBase_UnitOfMeasurement::set_unit_of_measurement | ( | const char * | unit_of_measurement | ) |
Manually set the unit of measurement.
Definition at line 99 of file entity_base.cpp.
|
protected |
Unit of measurement override.
Definition at line 182 of file entity_base.h.