mirror of
https://github.com/thooge/esp32-nmea2000-obp60.git
synced 2025-12-15 23:13:07 +01:00
allow to set default and hide for cfg values in hardware defs
This commit is contained in:
@@ -10,12 +10,14 @@ class GwConfigInterface{
|
||||
const char * initialValue;
|
||||
String value;
|
||||
bool secret=false;
|
||||
bool hidden=false;
|
||||
public:
|
||||
GwConfigInterface(const String &name, const char * initialValue, bool secret=false){
|
||||
GwConfigInterface(const String &name, const char * initialValue, bool secret=false, bool hidden=false){
|
||||
this->name=name;
|
||||
this->initialValue=initialValue;
|
||||
this->value=initialValue;
|
||||
this->secret=secret;
|
||||
this->hidden=hidden;
|
||||
}
|
||||
virtual String asString() const{
|
||||
return value;
|
||||
@@ -41,6 +43,9 @@ class GwConfigInterface{
|
||||
String getDefault() const {
|
||||
return initialValue;
|
||||
}
|
||||
bool isHidden() const {
|
||||
return hidden;
|
||||
}
|
||||
friend class GwConfigHandler;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user