Members of plugin::PluginCatalog<Base>. All take the shared (read) lock and are const except where noted.
std::vector<std::string> names( bool includeAliases = false ) const;
bool contains( key_type const& key ) const;
bool empty() const;
std::size_t size() const;
names
Returns the registered keys.
includeAliases | Result |
|---|---|
false (default) | only keys registered as primary — REGISTER, REGISTERBYNAME, REGISTER_WITH_CONFIG. |
true | every key, including REGISTERAS / REGISTERBYNICK aliases. |
Order is the std::map order — lexicographic by key.
Shape::catalog().names(); // { "Circle", "Ellipse", "Square" }
Shape::catalog().names(true); // { "Circle", "Ellipse", "Square", "oval", "◯" }
contains
true if key has an entry (alias or not). Equivalent to names(true) containing key, but without building the vector.
empty / size
empty() is true when no entries at all. size() counts all entries, aliases included — so size() can exceed names().size().
Shape::catalog().empty(); // false
Shape::catalog().size(); // 5 (3 primary + 2 aliases)
Shape::catalog().names().size(); // 3
Notes
- The returned
vectoris a snapshot — a concurrentinsert/eraseafter the call does not change it. size()counting aliases is intentional: it is the number of live map entries. Usenames().size()for "how many distinct plugins".

