1#ifndef PODIO_COLLECTIONIDTABLE_H
2#define PODIO_COLLECTIONIDTABLE_H
37 const std::vector<std::string>&
names()
const {
42 const std::vector<int>&
ids()
const {
43 return m_collectionIDs;
48 int add(
const std::string&
name);
55 return m_names.empty();
59 std::vector<int> m_collectionIDs{};
60 std::vector<std::string> m_names{};
61 mutable std::unique_ptr<std::mutex> m_mutex{
nullptr};
~CollectionIDTable()=default
CollectionIDTable(CollectionIDTable &&)=default
void print() const
Prints collection information.
bool present(const std::string &name) const
Check if collection name is known.
int add(const std::string &name)
bool empty() const
Does this table hold any information?
const std::vector< int > & ids() const
return the ids
CollectionIDTable & operator=(const CollectionIDTable &)=delete
int collectionID(const std::string &name) const
return collection ID for given name
const std::vector< std::string > & names() const
return registered names
CollectionIDTable & operator=(CollectionIDTable &&)=default
const std::string name(int collectionID) const
return name for given collection ID
CollectionIDTable(const CollectionIDTable &)=delete