mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-28 23:43:34 +08:00
Protected constructor of MapBase<>
This commit is contained in:
@@ -101,10 +101,6 @@ class UAVCAN_EXPORT MapBase : Noncopyable
|
|||||||
};
|
};
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
/// Derived class destructor must call removeAll();
|
|
||||||
~MapBase() { }
|
|
||||||
|
|
||||||
public:
|
|
||||||
MapBase(KVPair* static_buf, unsigned num_static_entries, IAllocator& allocator)
|
MapBase(KVPair* static_buf, unsigned num_static_entries, IAllocator& allocator)
|
||||||
: allocator_(allocator)
|
: allocator_(allocator)
|
||||||
, static_(static_buf)
|
, static_(static_buf)
|
||||||
@@ -113,6 +109,10 @@ public:
|
|||||||
assert(Key() == Key());
|
assert(Key() == Key());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Derived class destructor must call removeAll();
|
||||||
|
~MapBase() { }
|
||||||
|
|
||||||
|
public:
|
||||||
Value* access(const Key& key);
|
Value* access(const Key& key);
|
||||||
|
|
||||||
/// If entry with the same key already exists, it will be replaced
|
/// If entry with the same key already exists, it will be replaced
|
||||||
|
|||||||
Reference in New Issue
Block a user