20 #ifndef GEOS_MESH_FIELDS_HPP_
21 #define GEOS_MESH_FIELDS_HPP_
23 #include "codingUtilities/traits.hpp"
39 #define DECLARE_FIELD( NAME, \
51 static constexpr char const * key() \
56 using dataType = internal::typeHelper_t< TYPE >; \
58 static constexpr dataType defaultValue() \
61 static constexpr dataRepository::PlotLevel plotLevel = dataRepository::PlotLevel::PLOTLEVEL; \
63 static constexpr dataRepository::RestartFlags restartFlag = dataRepository::RestartFlags::RESTARTFLAG; \
65 static constexpr char const * description = DESCRIPTION; \
78 template<
typename TYPE,
bool HAS_TYPE = std::enable_if_t< traits::HasAlias_value_type< TYPE >, std::true_type >::value >
81 using type =
typename TYPE::value_type;
84 template<
typename TYPE >
85 struct typeHelper< TYPE, false >
90 template<
typename T >
91 using typeHelper_t =
typename typeHelper< T >::type;
116 "Element aperture." );
132 "Index of parent within the mesh object it is registered on." );
140 "Index of parent edge within the mesh object it is registered on." );
148 "Index of child within the mesh object it is registered on." );
156 "Time that the object was ruptured/split." );
164 "Unit normal vector to the surface." );
172 "Unit vector in the first tangent direction to the surface." );
180 "Unit vector in the second tangent direction to the surface." );
#define DECLARE_FIELD(NAME, KEY, TYPE, DEFAULT, PLOTLEVEL, RESTARTFLAG, DESCRIPTION)
Generates a traits struct.
Array< T, 2, PERMUTATION > array2d
Alias for 2D array.
Array< T, 1 > array1d
Alias for 1D array.
Trait struct for childIndex data.
Trait struct for elementAperture data.
Trait struct for elementArea data.
Trait struct for elementVolume data.
Trait struct for ghostRank data.
Trait struct for normalVector data.
Trait struct for parentEdgeIndex data.
Trait struct for parentIndex data.
Trait struct for ruptureTime data.
Trait struct for tangentVector1 data.
Trait struct for tangentVector2 data.