17#ifndef CONFIG_NETOBJ_H
18#define CONFIG_NETOBJ_H
80 virtual void CommitTestedValue(uint32_t permission_mask);
117 pend_val = val = ci.val;
128 pend_val = val = ci.val;
180 virtual void ExtendedSchema(
int fd,
int indent,
bool pretty) { DoSchemaLine(fd,
"format",
"ipv4", indent, pretty); };
236inline bool operator==(
const uint32_t i,
const CUR_IPADDR4 &j)
240inline bool operator!=(
const uint32_t i,
const CUR_IPADDR4 &j)
244inline bool operator>(
const uint32_t i,
const CUR_IPADDR4 &j)
248inline bool operator<(
const uint32_t i,
const CUR_IPADDR4 &j)
253inline bool operator==(
const CUR_IPADDR4 &i,
const uint32_t j)
257inline bool operator!=(
const CUR_IPADDR4 &i,
const uint32_t j)
261inline bool operator>(
const CUR_IPADDR4 &i,
const uint32_t j)
265inline bool operator<(
const CUR_IPADDR4 &i,
const uint32_t j)
278 config_chooser mode{
"Mode",
"DHCP",
"DHCP,DHCP w Fallback,Static,Disabled",
279 "DHCP,DHCP with backup static address,Static preconfigured address,Disabled"};
280 config_IPADDR4 addr{
"0.0.0.0",
"StaticAddr",
"Configured IP Address"};
281 config_IPADDR4 mask{
"0.0.0.0",
"StaticMask",
"Configured IP Mask"};
282 config_IPADDR4 gate{
"0.0.0.0",
"StaticGate",
"Configured IP Gateway"};
283 config_IPADDR4 dns1{
"0.0.0.0",
"StaticDNS1",
"Configured IP DNS(1)"};
284 config_IPADDR4 dns2{
"0.0.0.0",
"StaticDNS2",
"Configured IP DNS(2)"};
286 config_bool autoip{
true,
"AutoIPEn",
"Enable Auto IP"};
289 CUR_IPADDR4 cur_addr{
"ActiveAddr",
"Current IPV4 address in use"};
290 CUR_IPADDR4 cur_mask{
"ActiveMask",
"Current IPV4 mask in use"};
291 CUR_IPADDR4 cur_gate{
"ActiveGate",
"Current IPV4 gateway in use"};
292 CUR_IPADDR4 cur_dns1{
"ActiveDNS1",
"Current IPV4 dns(1) in use"};
293 CUR_IPADDR4 cur_dns2{
"ActiveDNS2",
"Current IPV4 dns(2) in use"};
294 CUR_IPADDR4 cur_auto{
"AutoIPAddr",
"Current IPV4 auto address in use"};
295 config_bool mac_dns {
true,
"EnableMacmDNS",
"Enable nburnxxxxxx.local using mac address"};
296 config_localname local_name{
"",
"LocalName",
"The local name to resolve with mDNS (.local assumed)"};
306 void Attach(
void *pb) { m_pBlock_if = pb; }
343 virtual void ExtendedSchema(
int fd,
int indent,
bool pretty) { DoSchemaLine(fd,
"format",
"ipv6", indent, pretty); };
356 config_chooser mode{
"Mode",
"DHCP",
"DHCP,DHCP w Fallback,Static,Disabled",
357 "DHCP,DHCP with backup static address,Static preconfigured address,Disabled"};
358 config_IPADDR addr{
"0::0",
"StaticAddr",
"Configured IPV6 address"};
359 config_IPADDR dns1{
"0::0",
"StaticDNS1",
"Configured IPV6 DNS(1)"};
360 config_IPADDR dns2{
"0::0",
"StaticDNS2",
"Configured IPV6 DNS(2)"};
362 Dynamic_IPADDR address_list{
"ActiveAddr", 0,
this,
"Active currently in user IPV6 addres(s)"};
363 Dynamic_IPADDR dns_list{
"ActiveDNS", 1,
this,
"Active currently in user IPV6 DNS(s)"};
364 Dynamic_IPADDR route_list{
"ActiveRoute", 2,
this,
"Active currently in user IPV6 routes"};
Definition config_netobj.h:139
virtual void CommitTestedValue(uint32_t permission_mask)
Definition config_netobj.h:161
virtual void ExtendedSchema(int fd, int indent, bool pretty)
Definition config_netobj.h:180
bool NotNull() const
Definition config_netobj.h:189
bool IsGlobalBroadCast() const
Definition config_netobj.h:197
CUR_IPADDR4(const char *name, const char *desc=NULL)
Definition config_netobj.h:144
virtual void GetTextValue(NBString &s)
Definition config_netobj.h:157
virtual void GetTypeValue(NBString &s)
Definition config_netobj.h:182
bool IsMultiCast() const
Definition config_netobj.h:195
bool IsNull() const
Definition config_netobj.h:187
bool IsLoopBack() const
Definition config_netobj.h:193
bool IsAutoIP()
Definition config_netobj.h:199
virtual ConfigTestResult TestNewValue(ParsedJsonDataSet &pjs)
Definition config_netobj.h:159
void SetNull()
Definition config_netobj.h:191
Dynamic_IPADDR.
Definition config_netobj.h:318
virtual void ExtendedSchema(int fd, int indent, bool pretty)
Definition config_netobj.h:343
virtual ConfigTestResult TestNewValue(ParsedJsonDataSet &pjs)
Definition config_netobj.h:337
void AddToJsonOutObject(ParsedJsonDataSet &jo, const char *name)
Dynamic_IPADDR(const char *name, int item, I6Record *pI6, const char *desc=NULL)
Definition config_netobj.h:328
virtual void GetTypeValue(NBString &s)
Definition config_netobj.h:345
virtual void GetTextValue(NBString &s)
virtual void CommitTestedValue(uint32_t permission_mask)
Definition config_netobj.h:339
Definition config_netobj.h:274
void Attach(void *pb)
Definition config_netobj.h:306
I4Record(const char *name, const char *desc=NULL)
Definition config_netobj.h:301
void GetReportItem(NBString &s, int item)
Definition config_netobj.h:352
void Attach(int nif)
Definition config_netobj.h:372
I6Record(const char *name, const char *desc=NULL)
Definition config_netobj.h:369
int GetnIf()
Definition config_netobj.h:376
void ReportGetTextValue(NBString &s, int item)
Used to store and manipulate IPv4 addresses in dual stack mode.
Definition nettypes.h:208
bool IsNull() const
Check if the IP address is null.
Definition nettypes.h:262
bool IsLoopBack() const
Check if the IP address is the loopback address for the interface.
Definition nettypes.h:287
bool IsAutoIP()
Check if the IPADDR4 object contains an AutoIP address.
Definition nettypes.h:324
bool IsMultiCast() const
Check if the IPADDR4 object contains a Multicast IP address the interface.
Definition nettypes.h:296
bool NotNull() const
Check if the IP address is not null.
Definition nettypes.h:271
void SetNull()
Set the IP address to null.
Definition nettypes.h:278
bool IsGlobalBroadCast() const
Check if the IPADDR4 object contains a global broadcast address: 255.255.255.255.
Definition nettypes.h:315
Lightweight alternative to C++ CString class.
Definition nbstring.h:118
A class to create, read, and modify a JSON object.
Definition json_lexer.h:530
Configuration Variable for IPADDR4 (IPv4) object types.
Definition config_obj.h:1404
Configuration Variable for IPADDR (IPv6) object type.
Definition config_obj.h:1580
Boolean Configuration Variable.
Definition config_obj.h:932
Chooser Configuration Variable - Select From a List of Items.
Definition config_obj.h:1915
Configure device network name.
Definition config_netobj.h:26
config_localname & operator=(const NBString &s)
Assign the config_localname object value from a NBString object.
Definition config_netobj.h:104
config_localname(config_obj &owner, const char *def_val, const char *name, const char *desc=NULL)
Object constructor with the parent/owner leaf parameter.
Definition config_netobj.h:66
config_localname & operator=(const char *p)
Assign the config_localname object value from a const char* value.
Definition config_netobj.h:93
config_localname(config_obj &owner, NBString def_val, const char *name, const char *desc=NULL)
Object constructor with the parent/owner leaf parameter.
Definition config_netobj.h:38
config_localname & operator=(const config_localname &ci)
Copy one config_localname object to another.
Definition config_netobj.h:126
config_localname & operator=(const config_string &ci)
Copy a config_string object to a config_localname object.
Definition config_netobj.h:115
config_localname(const char *def_val, const char *name, const char *desc=NULL)
Object constructor.
Definition config_netobj.h:78
config_localname(NBString def_val, const char *name, const char *desc=NULL)
Object constructor.
Definition config_netobj.h:54
Base class used to create configuration objects.
Definition config_obj.h:277
String Configuration Variable.
Definition config_obj.h:1055
Base class used to create a configuration value.
Definition config_obj.h:446
Configuration object header file.
const uint32_t fConfigNoSave
Do not save to flash memory when save functions are called.
Definition config_obj.h:75
const uint32_t fConfigReadOnly
Variable is read-only.
Definition config_obj.h:72