mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
* RegionMap: get/set Home Region
* repeater: admin CLI, changed "allowf *", "denyf *", added "home"
This commit is contained in:
parent
7419ed71f7
commit
cf547da857
3 changed files with 42 additions and 15 deletions
|
|
@ -20,7 +20,7 @@ struct RegionEntry {
|
|||
|
||||
class RegionMap {
|
||||
TransportKeyStore* _store;
|
||||
uint16_t next_id;
|
||||
uint16_t next_id, home_id;
|
||||
uint16_t num_regions;
|
||||
RegionEntry regions[MAX_REGION_ENTRIES];
|
||||
RegionEntry wildcard;
|
||||
|
|
@ -39,6 +39,8 @@ public:
|
|||
RegionEntry* findByName(const char* name);
|
||||
RegionEntry* findByNamePrefix(const char* prefix);
|
||||
RegionEntry* findById(uint16_t id);
|
||||
RegionEntry* getHomeRegion(); // NOTE: can be NULL
|
||||
void setHomeRegion(const RegionEntry* home);
|
||||
bool removeRegion(const RegionEntry& region);
|
||||
bool clear();
|
||||
void resetFrom(const RegionMap& src) { num_regions = 0; next_id = src.next_id; }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue