OGS
MeshLib::Properties Class Reference

Detailed Description

Property manager on mesh items. Class Properties manages scalar, vector or matrix properties. For instance in groundwater flow porosity is a scalar property and permeabilty can be stored as a tensor property. Properties are assigned to mesh items, i.e. Node or Element objects. The createNewPropertyVector() method first creates a PropertyVector of template type T (scalar, vector or matrix). This class stores the PropertyVector, accessible by a combination of the name and the type of the mesh item (Node or Element).

Definition at line 24 of file MeshLib/Properties.h.

#include <Properties.h>

Public Member Functions

template<typename T>
PropertyVector< T > * createNewPropertyVector (std::string_view name, MeshItemType mesh_item_type, std::size_t n_components=1)
template<typename T>
PropertyVector< T > * createNewPropertyVector (std::string_view name, MeshItemType mesh_item_type, std::size_t n_property_values, std::size_t n_components)
template<typename T>
bool existsPropertyVector (std::string_view name) const
template<typename T>
bool existsPropertyVector (std::string_view name, MeshItemType const mesh_item_type, int const number_of_components) const
template<typename T>
PropertyVector< T > const * getPropertyVector (std::string_view name) const
template<typename T>
PropertyVector< T > * getPropertyVector (std::string_view name)
template<typename T>
PropertyVector< T > const * getPropertyVector (std::string_view name, MeshItemType const item_type, int const n_components) const
template<typename T>
PropertyVector< T > * getPropertyVector (std::string_view name, MeshItemType const item_type, int const n_components)
void removePropertyVector (std::string_view name)
bool hasPropertyVector (std::string_view name) const
template<typename T>
bool hasPropertyVector (std::string_view name, MeshItemType const item_type) const
std::vector< std::string > getPropertyVectorNames () const
std::vector< std::string > getPropertyVectorNames (MeshLib::MeshItemType t) const
Properties excludeCopyProperties (std::vector< std::size_t > const &exclude_elem_ids, std::vector< std::size_t > const &exclude_node_ids) const
Properties excludeCopyProperties (std::vector< MeshItemType > const &exclude_mesh_item_types) const
 Properties ()=default
 Properties (Properties const &properties)
 Properties (Properties &&properties)=default
Propertiesoperator= (Properties const &properties)
Propertiesoperator= (Properties &&properties)=default
 ~Properties ()
std::map< std::string, PropertyVectorBase * >::const_iterator begin () const
std::map< std::string, PropertyVectorBase * >::const_iterator end () const
std::map< std::string, PropertyVectorBase * >::iterator begin ()
std::map< std::string, PropertyVectorBase * >::iterator end ()
std::map< std::string, PropertyVectorBase * >::size_type size () const
std::map< std::string, PropertyVectorBase * >::size_type size (MeshItemType const mesh_item_type) const
template<typename T>
PropertyVector< T > const * getPropertyVector (std::string_view name) const
template<typename T>
PropertyVector< T > const * getPropertyVector (std::string_view name, MeshItemType const item_type, int const n_components) const

Private Attributes

std::map< std::string, PropertyVectorBase * > _properties

Constructor & Destructor Documentation

◆ Properties() [1/3]

◆ Properties() [2/3]

MeshLib::Properties::Properties ( Properties const & properties)

Definition at line 94 of file Properties.cpp.

95 : _properties(properties._properties)
96{
97 for (auto& name_vector_pair : _properties)
98 {
99 PropertyVectorBase* t(name_vector_pair.second->clone({}));
100 name_vector_pair.second = t;
101 }
102}
std::map< std::string, PropertyVectorBase * > _properties

References Properties(), and _properties.

◆ Properties() [3/3]

MeshLib::Properties::Properties ( Properties && properties)
default

References Properties().

◆ ~Properties()

MeshLib::Properties::~Properties ( )

Definition at line 123 of file Properties.cpp.

124{
125 for (auto name_vector_pair : _properties)
126 {
127 delete name_vector_pair.second;
128 }
129}

References _properties.

Member Function Documentation

◆ begin() [1/2]

std::map< std::string, PropertyVectorBase * >::iterator MeshLib::Properties::begin ( )

Definition at line 143 of file Properties.cpp.

144{
145 return _properties.begin();
146}

References _properties.

◆ begin() [2/2]

std::map< std::string, PropertyVectorBase * >::const_iterator MeshLib::Properties::begin ( ) const

Definition at line 131 of file Properties.cpp.

133{
134 return _properties.cbegin();
135}

References _properties.

Referenced by size().

◆ createNewPropertyVector() [1/2]

template<typename T>
PropertyVector< T > * MeshLib::Properties::createNewPropertyVector ( std::string_view name,
MeshItemType mesh_item_type,
std::size_t n_components = 1 )

Method creates a PropertyVector if a PropertyVector with the same name and the same type T was not already created before. In case there exists already such a PropertyVector a nullptr is returned. There are two versions of this method. This method is used when every mesh item at hand has its own property value, i.e. \(n\) mesh item and \(n\) different property values. The user has to ensure the correct usage of the vector later on.

Template Parameters
Ttype of the property value
Parameters
namethe name of the property
mesh_item_typefor instance node or element assigned properties
n_componentsnumber of components for each tuple
Returns
A pointer to a PropertyVector on success and a nullptr otherwise.

Definition at line 9 of file Properties-impl.h.

12{
13 auto it(_properties.find(std::string(name)));
14 if (it != _properties.end())
15 {
16 ERR("A property of the name '{:s}' is already assigned to the mesh.",
17 name);
18 return nullptr;
19 }
20 auto entry_info(_properties.insert(
21 std::make_pair(std::string(name),
22 new PropertyVector<T>(std::string(name), mesh_item_type,
23 n_components))));
24 return static_cast<PropertyVector<T>*>((entry_info.first)->second);
25}
void ERR(fmt::format_string< Args... > fmt, Args &&... args)
Definition Logging.h:40

References _properties, and ERR().

Referenced by CreateStructuredGridDialog::accept(), addGlobalIDsToMesh(), MeshLib::addPropertyToMesh(), ApplicationUtils::addVtkGhostTypeProperty(), castPropertyVectorToPropertyVector(), MeshToolsLib::RasterToMesh::convert(), MeshLib::VtkMeshConverter::convertTypedArray(), copyDoubleValuedFieldDataToPointCloud(), anonymous_namespace{MeshRevision.cpp}::copyProperty(), ApplicationUtils::copyPropertyVector(), MeshLib::IO::NodePartitionedMeshReader::createPropertyVectorPart(), MeshLib::IO::NodePartitionedMeshReader::createSpecificPropertyVectorPart(), MeshToolsLib::MeshLayerMapper::createStaticLayers(), LayeredMeshGenerator::getMesh(), MeshLib::IO::Legacy::MeshIO::loadMeshFromFile(), main(), MeshToolsLib::MeshGenerator::VoxelGridFromMesh::mapArray(), FileIO::Gocad::GocadAsciiReader::parseProperties(), FileIO::Gocad::GocadAsciiReader::readData(), FileIO::GMSH::readGMSHMesh(), FileIO::GMSInterface::readMesh(), FileIO::SwmmInterface::readSwmmInputToLineMesh(), FileIO::TetGenInterface::readTetGenMesh(), MeshToolsLib::Mesh2MeshPropertyInterpolation::setPropertiesForMesh(), and writeDataToMesh().

◆ createNewPropertyVector() [2/2]

template<typename T>
PropertyVector< T > * MeshLib::Properties::createNewPropertyVector ( std::string_view name,
MeshItemType mesh_item_type,
std::size_t n_property_values,
std::size_t n_components )

Definition at line 28 of file Properties-impl.h.

31{
32 auto it(_properties.find(std::string(name)));
33 if (it != _properties.end())
34 {
35 ERR("A property of the name '{:s}' is already assigned to the mesh.",
36 name);
37 return nullptr;
38 }
39 auto entry_info(_properties.insert(std::make_pair(
40 std::string(name),
41 new PropertyVector<T>(n_property_values, std::string(name),
42 mesh_item_type, n_components))));
43 return static_cast<PropertyVector<T>*>((entry_info.first)->second);
44}

References _properties, and ERR().

◆ end() [1/2]

std::map< std::string, PropertyVectorBase * >::iterator MeshLib::Properties::end ( )

Definition at line 148 of file Properties.cpp.

149{
150 return _properties.end();
151}

References _properties.

◆ end() [2/2]

std::map< std::string, PropertyVectorBase * >::const_iterator MeshLib::Properties::end ( ) const

Definition at line 137 of file Properties.cpp.

139{
140 return _properties.cend();
141}

References _properties.

Referenced by size().

◆ excludeCopyProperties() [1/2]

Properties MeshLib::Properties::excludeCopyProperties ( std::vector< MeshItemType > const & exclude_mesh_item_types) const

copy all PropertyVector objects stored in the (internal) map but PropertyVector objects with the given MeshItemType are excluded.

Definition at line 72 of file Properties.cpp.

74{
75 Properties new_properties;
76 for (auto name_vector_pair : _properties)
77 {
78 if (std::find(exclude_mesh_item_types.begin(),
79 exclude_mesh_item_types.end(),
80 name_vector_pair.second->getMeshItemType()) !=
81 exclude_mesh_item_types.end())
82 {
83 continue;
84 }
85
86 std::vector<std::size_t> const exclude_positions{};
87 new_properties._properties.insert(
88 std::make_pair(name_vector_pair.first,
89 name_vector_pair.second->clone(exclude_positions)));
90 }
91 return new_properties;
92}

References Properties(), and _properties.

◆ excludeCopyProperties() [2/2]

Properties MeshLib::Properties::excludeCopyProperties ( std::vector< std::size_t > const & exclude_elem_ids,
std::vector< std::size_t > const & exclude_node_ids ) const

copy all PropertyVector objects stored in the (internal) map but only those nodes/elements of a PropertyVector whose ids are not in the vectors exclude_*_ids.

Definition at line 48 of file Properties.cpp.

51{
52 Properties exclude_copy;
53 for (auto name_vector_pair : _properties)
54 {
55 if (name_vector_pair.second->getMeshItemType() == MeshItemType::Cell)
56 {
57 exclude_copy._properties.insert(std::make_pair(
58 name_vector_pair.first,
59 name_vector_pair.second->clone(exclude_elem_ids)));
60 }
61 else if (name_vector_pair.second->getMeshItemType() ==
63 {
64 exclude_copy._properties.insert(std::make_pair(
65 name_vector_pair.first,
66 name_vector_pair.second->clone(exclude_node_ids)));
67 }
68 }
69 return exclude_copy;
70}

References Properties(), _properties, MeshLib::Cell, and MeshLib::Node.

Referenced by MeshToolsLib::convertToLinearMesh(), MeshToolsLib::createQuadraticOrderMesh(), MeshToolsLib::removeElements(), and MeshToolsLib::removeNodes().

◆ existsPropertyVector() [1/2]

template<typename T>
bool MeshLib::Properties::existsPropertyVector ( std::string_view name) const

Checks if a property vector with given name and the given type exists.

Parameters
namename of the requested property vector

Definition at line 47 of file Properties-impl.h.

48{
49 auto it(_properties.find(std::string(name)));
50 // Check that a PropertyVector with the appropriate name exists.
51 if (it == _properties.end())
52 {
53 return false;
54 }
55
56 if (dynamic_cast<PropertyVector<T> const*>(it->second) == nullptr)
57 {
58 WARN("Property '{}' exists but does not have the requested type {}.",
60 return false;
61 }
62
63 return true;
64}
void WARN(fmt::format_string< Args... > fmt, Args &&... args)
Definition Logging.h:34
std::string typeToString()

References _properties, BaseLib::typeToString(), and WARN().

Referenced by MeshLib::ElementStatus::ElementStatus(), ProcessLib::SolutionDependentDirichletBoundaryCondition::SolutionDependentDirichletBoundaryCondition(), MeshElementRemovalDialog::accept(), ProcessLib::addBulkMeshPropertyToSubMesh(), addGlobalIDsToMesh(), MeshToolsLib::addLayerToMesh(), ProcessLib::checkParametersOfDirichletBoundaryCondition(), copyDoubleValuedFieldDataToPointCloud(), anonymous_namespace{MeshRevision.cpp}::copyProperty(), MeshLib::getIntegrationPointMetaData(), MeshLib::getOrCreateMeshProperty(), getSurfaceIntegratedValuesForNodes(), main(), MeshElementRemovalDialog::on_scalarArrayComboBox_currentIndexChanged(), reorderProperty(), MeshLib::scaleMeshPropertyVector(), ProcessLib::setIPDataInitialConditions(), MeshToolsLib::Mesh2MeshPropertyInterpolation::setPropertiesForMesh(), transfer(), and FileIO::TetGenInterface::write2dElements().

◆ existsPropertyVector() [2/2]

template<typename T>
bool MeshLib::Properties::existsPropertyVector ( std::string_view name,
MeshItemType const mesh_item_type,
int const number_of_components ) const

Checks if a property vector with given type T, name, mesh_item_type, and number_of_components exists.

Definition at line 67 of file Properties-impl.h.

70{
71 auto const it = _properties.find(std::string(name));
72 if (it == _properties.end())
73 {
74 return false;
75 }
76
77 auto property = dynamic_cast<PropertyVector<T>*>(it->second);
78 if (property == nullptr)
79 {
80 WARN("Property {} exists but does not have the requested type {}.",
82 return false;
83 }
84 if (property->getMeshItemType() != mesh_item_type)
85 {
86 WARN(
87 "Property {} exists but does not have the requested mesh item type "
88 "{}.",
89 name, toString(mesh_item_type));
90 return false;
91 }
92 if (property->getNumberOfGlobalComponents() != number_of_components)
93 {
94 WARN(
95 "Property {} exists but does not have the requested number of "
96 "components {}",
97 name, number_of_components);
98 return false;
99 }
100 return true;
101}
static constexpr char const * toString(const MeshItemType t)
Returns a char array for a specific MeshItemType.
Definition MeshEnums.h:26

References _properties, MeshLib::toString(), BaseLib::typeToString(), and WARN().

◆ getPropertyVector() [1/6]

template<typename T>
PropertyVector< T > * MeshLib::Properties::getPropertyVector ( std::string_view name)

Returns a property vector with given name or aborts calling OGS_FATAL if no such property vector exists.

Definition at line 112 of file Properties-impl.h.

113{
114 auto it(_properties.find(std::string(name)));
115 if (it == _properties.end())
116 {
117 OGS_FATAL(
118 "A PropertyVector with the specified name '{:s}' is not available.",
119 name);
120 }
121 if (!dynamic_cast<PropertyVector<T>*>(it->second))
122 {
123 OGS_FATAL(
124 "The PropertyVector '{:s}' has a different type than the requested "
125 "PropertyVector.",
126 name);
127 }
128 return dynamic_cast<PropertyVector<T>*>(it->second);
129}
#define OGS_FATAL(...)
Definition Error.h:10

References _properties, and OGS_FATAL.

◆ getPropertyVector() [2/6]

template<typename T>
PropertyVector< T > const * MeshLib::Properties::getPropertyVector ( std::string_view name) const

Definition at line 104 of file Properties-impl.h.

106{
107 return const_cast<PropertyVector<T> const*>(
108 const_cast<Properties*>(this)->getPropertyVector<T>(name));
109}

References Properties().

◆ getPropertyVector() [3/6]

template<typename T>
PropertyVector< T > const * MeshLib::Properties::getPropertyVector ( std::string_view name) const

Returns a property vector with given name or aborts calling OGS_FATAL if no such property vector exists.

Referenced by ProcessLib::LIE::HydroMechanics::HydroMechanicsProcess< DisplacementDim >::HydroMechanicsProcess(), ProcessLib::LIE::PostProcessTool::PostProcessTool(), ProcessLib::LIE::SmallDeformation::SmallDeformationProcess< DisplacementDim >::SmallDeformationProcess(), ProcessLib::addBulkMeshPropertyToSubMesh(), MeshToolsLib::addLayerToMesh(), FileIO::Gocad::GocadAsciiReader::appendSectionMaterialIds(), MeshLib::bulkElementIDs(), MeshLib::bulkNodeIDs(), castPropertyVectorToPropertyVector(), MeshToolsLib::ElementValueModification::condense(), anonymous_namespace{MeshRevision.cpp}::copyProperty(), copyPropertyVector(), ParameterLib::createGroupBasedParameter(), ParameterLib::createMeshElementParameter(), ParameterLib::createMeshNodeParameter(), ParameterLib::createRandomFieldMeshElementParameter(), extractMatGroup(), getRegularElements(), getSurfaceIntegratedValuesForNodes(), MeshToolsLib::MeshGenerator::VoxelGridFromMesh::mapArray(), MeshElementRemovalDialog::on_scalarArrayComboBox_currentIndexChanged(), MeshToolsLib::overwriteMeshFieldDataByMaterialIDs(), ApplicationUtils::NodeWiseMeshPartitioner::renumberBulkIdsProperty(), reorderProperty(), MeshToolsLib::ElementValueModification::replace(), MeshGeoToolsLib::resetMeshElementProperty(), MeshLib::scaleMeshPropertyVector(), MeshToolsLib::ElementValueModification::setByElementType(), setMaterialIDs(), MeshToolsLib::Mesh2MeshPropertyInterpolation::setPropertiesForMesh(), transfer(), transferPropertiesFromPartitionedMeshToUnpartitionedMesh(), FileIO::TetGenInterface::write2dElements(), and FileIO::TetGenInterface::write3dElements().

◆ getPropertyVector() [4/6]

template<typename T>
PropertyVector< T > * MeshLib::Properties::getPropertyVector ( std::string_view name,
MeshItemType const item_type,
int const n_components )

Non-const version of getPropertyVector returns a property vector with given name, item_type and number_of_components or calls OGS_FATAL if no such property vector exists.

Definition at line 188 of file Properties-impl.h.

191{
192 auto const it = _properties.find(std::string(name));
193 if (it == _properties.end())
194 {
195 OGS_FATAL(
196 "A PropertyVector with name '{:s}' does not exist in the mesh.",
197 name);
198 }
199
200 auto property = dynamic_cast<PropertyVector<T>*>(it->second);
201 if (property == nullptr)
202 {
203 OGS_FATAL(
204 "Could not cast the data type of the PropertyVector '{:s}' to "
205 "requested data type.",
206 name);
207 }
208 if (property->getMeshItemType() != item_type)
209 {
210 OGS_FATAL(
211 "The PropertyVector '{:s}' has type '{:s}'. A '{:s}' field is "
212 "requested.",
213 name, toString(property->getMeshItemType()), toString(item_type));
214 }
215 if (property->getNumberOfGlobalComponents() != n_components)
216 {
217 OGS_FATAL(
218 "PropertyVector '{:s}' has {:d} components, {:d} components are "
219 "needed.",
220 name, property->getNumberOfGlobalComponents(), n_components);
221 }
222 return property;
223}

References _properties, OGS_FATAL, and MeshLib::toString().

◆ getPropertyVector() [5/6]

template<typename T>
PropertyVector< T > const * MeshLib::Properties::getPropertyVector ( std::string_view name,
MeshItemType const item_type,
int const n_components ) const

Definition at line 149 of file Properties-impl.h.

152{
153 auto const it = _properties.find(std::string(name));
154 if (it == _properties.end())
155 {
156 OGS_FATAL(
157 "A PropertyVector with name '{:s}' does not exist in the mesh.",
158 name);
159 }
160
161 auto property = dynamic_cast<PropertyVector<T>*>(it->second);
162 if (property == nullptr)
163 {
164 OGS_FATAL(
165 "Could not cast the data type of the PropertyVector '{:s}' (type: "
166 "'{:s}') to the requested data type '{:s}'.",
167 name, BaseLib::typeToString(*it->second),
168 BaseLib::typeToString<PropertyVector<T>>());
169 }
170 if (property->getMeshItemType() != item_type)
171 {
172 OGS_FATAL(
173 "The PropertyVector '{:s}' has type '{:s}'. A '{:s}' field is "
174 "requested.",
175 name, toString(property->getMeshItemType()), toString(item_type));
176 }
177 if (property->getNumberOfGlobalComponents() != n_components)
178 {
179 OGS_FATAL(
180 "PropertyVector '{:s}' has {:d} components, {:d} components are "
181 "needed.",
182 name, property->getNumberOfGlobalComponents(), n_components);
183 }
184 return property;
185}

References _properties, OGS_FATAL, MeshLib::toString(), and BaseLib::typeToString().

◆ getPropertyVector() [6/6]

template<typename T>
PropertyVector< T > const * MeshLib::Properties::getPropertyVector ( std::string_view name,
MeshItemType const item_type,
int const n_components ) const

Returns a property vector with given name, item_type and number_of_components or aborts calling OGS_FATAL if no such property vector exists.

References Properties().

◆ getPropertyVectorNames() [1/2]

std::vector< std::string > MeshLib::Properties::getPropertyVectorNames ( ) const

Definition at line 25 of file Properties.cpp.

26{
27 std::vector<std::string> names;
28 std::transform(_properties.begin(), _properties.end(),
29 std::back_inserter(names),
30 [](auto const& pair) { return std::string(pair.first); });
31 return names;
32}
constexpr ranges::views::view_closure names
For an element of a range view return its name.
Definition Mesh.h:227

References _properties.

Referenced by anonymous_namespace{MeshRevision.cpp}::copyProperties(), main(), ProcessLib::Output::prepareSubmesh(), and MeshLib::IO::writeMeshToFile().

◆ getPropertyVectorNames() [2/2]

std::vector< std::string > MeshLib::Properties::getPropertyVectorNames ( MeshLib::MeshItemType t) const

Definition at line 34 of file Properties.cpp.

36{
37 std::vector<std::string> names;
38 for (auto p : _properties)
39 {
40 if (p.second->getMeshItemType() == t)
41 {
42 names.emplace_back(p.first);
43 }
44 }
45 return names;
46}

References _properties.

◆ hasPropertyVector() [1/2]

bool MeshLib::Properties::hasPropertyVector ( std::string_view name) const

Check if a PropertyVector accessible by the name is already stored within the Properties object.

Parameters
namethe name of the property (for instance porosity)

Definition at line 20 of file Properties.cpp.

21{
22 return _properties.find(std::string(name)) != _properties.end();
23}

References _properties.

Referenced by ProcessLib::LIE::PostProcessTool::PostProcessTool(), ProcessLib::checkParametersOfDirichletBoundaryCondition(), MeshToolsLib::overwriteMeshFieldDataByMaterialIDs(), ApplicationUtils::NodeWiseMeshPartitioner::renumberBulkIdsProperty(), and anonymous_namespace{IdentifySubdomainMesh.cpp}::updateOrCheckExistingSubdomainProperty().

◆ hasPropertyVector() [2/2]

template<typename T>
bool MeshLib::Properties::hasPropertyVector ( std::string_view name,
MeshItemType const item_type ) const

Check if a PropertyVector accessible by the name and by the item type is already stored within the Properties object.

Parameters
namethe name of the property, e.g. porosity.
item_typethe type of mesh entity, e.g. CELL.

Definition at line 132 of file Properties-impl.h.

134{
135 auto const it = _properties.find(std::string(name));
136
137 if (it == _properties.end())
138 {
139 return false;
140 }
141
142 auto property = dynamic_cast<PropertyVector<T>*>(it->second);
143
144 return (property == nullptr) ? false
145 : property->getMeshItemType() == item_type;
146}

References _properties, and MeshLib::PropertyVectorBase::getMeshItemType().

◆ operator=() [1/2]

Properties & MeshLib::Properties::operator= ( Properties && properties)
default

References Properties().

◆ operator=() [2/2]

Properties & MeshLib::Properties::operator= ( Properties const & properties)

Definition at line 104 of file Properties.cpp.

105{
106 if (&properties == this)
107 {
108 return *this;
109 }
110
111 _properties = properties._properties;
112 std::vector<std::size_t> exclude_positions;
113 for (auto& name_vector_pair : _properties)
114 {
115 PropertyVectorBase* t(
116 name_vector_pair.second->clone(exclude_positions));
117 name_vector_pair.second = t;
118 }
119
120 return *this;
121}

References Properties(), and _properties.

◆ removePropertyVector()

void MeshLib::Properties::removePropertyVector ( std::string_view name)

Definition at line 8 of file Properties.cpp.

9{
10 auto it(_properties.find(std::string(name)));
11 if (it == _properties.end())
12 {
13 WARN("A property of the name '{:s}' does not exist.", name);
14 return;
15 }
16 delete it->second;
17 _properties.erase(it);
18}

References _properties, and WARN().

Referenced by parseOverwriteMeshData().

◆ size() [1/2]

std::map< std::string, PropertyVectorBase * >::size_type MeshLib::Properties::size ( ) const

Definition at line 153 of file Properties.cpp.

154{
155 return _properties.size();
156}

References _properties.

Referenced by ApplicationUtils::writeProperties().

◆ size() [2/2]

std::map< std::string, PropertyVectorBase * >::size_type MeshLib::Properties::size ( MeshItemType const mesh_item_type) const

Definition at line 158 of file Properties.cpp.

160{
161 return count_if(begin(), end(),
162 [&](auto const p)
163 { return p.second->getMeshItemType() == mesh_item_type; });
164}
std::map< std::string, PropertyVectorBase * >::const_iterator begin() const
std::map< std::string, PropertyVectorBase * >::const_iterator end() const

References begin(), and end().

Member Data Documentation

◆ _properties

std::map<std::string, PropertyVectorBase*> MeshLib::Properties::_properties
private

The documentation for this class was generated from the following files: