Go to the documentation of this file.
7 #ifndef IOSS_Ioss_FieldManager_h
8 #define IOSS_Ioss_FieldManager_h
16 #include <unordered_map>
39 void erase(
const std::string &field_name);
42 bool exists(
const std::string &field_name)
const;
44 Field get(
const std::string &field_name)
const;
45 const Field &
getref(
const std::string &field_name)
const;
57 #if defined(IOSS_THREADSAFE)
58 mutable std::mutex m_;
std::vector< std::string > NameList
Definition: Ioss_CodeTypes.h:27
Holds metadata for bulk data associated with a GroupingEntity.
Definition: Ioss_Field.h:22
const Field & getref(const std::string &field_name) const
Get a reference to a field from the field manager.
Definition: Ioss_FieldManager.C:65
bool exists(const std::string &field_name) const
Checks if a field with a given name exists in the field manager.
Definition: Ioss_FieldManager.C:37
FieldManager(const FieldManager &other)
Definition: Ioss_FieldManager.h:29
void add(const Field &new_field)
Add a field to the field manager.
Definition: Ioss_FieldManager.C:22
A collection of Ioss::Field objects.
Definition: Ioss_FieldManager.h:26
FieldMapType::value_type FieldValuePair
Definition: Ioss_FieldManager.h:21
The main namespace for the Ioss library.
Definition: Ioad_DatabaseIO.C:40
FieldMapType fields
Definition: Ioss_FieldManager.h:56
std::unordered_map< std::string, Field > FieldMapType
Definition: Ioss_FieldManager.h:20
FieldManager & operator=(const FieldManager &)=delete
int describe(NameList *names) const
Get the names of all fields in the field manager.
Definition: Ioss_FieldManager.C:97
Field get(const std::string &field_name) const
Get a field from the field manager.
Definition: Ioss_FieldManager.C:50
void erase(const std::string &field_name)
Remove a field from the field manager.
Definition: Ioss_FieldManager.C:80
RoleType
Definition: Ioss_Field.h:49
size_t count() const
Get the number of fields in the field manager.
Definition: Ioss_FieldManager.C:138