14#include "arcane/core/VariableInfo.h"
16#include "arcane/utils/FatalErrorException.h"
17#include "arcane/utils/StringBuilder.h"
19#include "arcane/core/datatype/DataTypeTraits.h"
97 return DataStorageTypeInfo(basic_data_type, nb_basic,
dimension, multi_tag);
104VariableInfo(
const String& local_name,
const String& item_family_name,
105 const String& item_group_name,
108:
VariableInfo(local_name, item_family_name, item_group_name, mesh_name,
109 VariableTypeInfo(item_kind, data_type, dimension, multi_tag, !item_group_name.null()),
110 _internalGetStorageTypeInfo(data_type, dimension, multi_tag))
118VariableInfo(
const String& local_name,
const String& item_family_name,
119 const String& item_group_name,
120 const String& mesh_name,
121 const VariableTypeInfo& var_type_info,
122 const DataStorageTypeInfo& storage_info)
123: m_local_name(local_name)
124, m_item_family_name(item_family_name)
125, m_item_group_name(item_group_name)
126, m_mesh_name(mesh_name)
127, m_variable_type_info(var_type_info)
128, m_storage_type_info(storage_info)
130 if (m_item_family_name.null())
131 m_item_family_name = _defaultFamilyName();
147 switch (itemKind()) {
149 ARCANE_FATAL(
"No default family for 'particle' variable '{0}'", m_local_name);
151 ARCANE_FATAL(
"No default family for 'dof' variable '{0}'", m_local_name);
153 family_name = ItemTraitsT<Node>::defaultFamilyName();
156 family_name = ItemTraitsT<Edge>::defaultFamilyName();
159 family_name = ItemTraitsT<Face>::defaultFamilyName();
162 family_name = ItemTraitsT<Cell>::defaultFamilyName();
181_computeFullName()
const
183 StringBuilder full_name;
184 if (m_mesh_name.null()) {
185 full_name = String();
188 full_name = m_mesh_name;
192 if (m_item_family_name.null()) {
193 full_name += m_local_name;
196 full_name += m_item_family_name;
198 full_name += m_local_name;
200 m_full_name = full_name.toString();
207setDefaultItemGroupName()
209 if (!m_item_group_name.null())
212 m_item_group_name =
"All" + m_item_family_name +
"s";
#define ARCANE_FATAL(...)
Macro throwing a FatalErrorException.
Type information for a data container.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of elements of the base type.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of elements of the base type.
static constexpr int nbBasicType()
Number of elements of the base type.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of elements of the base type.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of elements of the base type.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of base type elements.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of base type elements.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of elements of the base type.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of base type elements.
static constexpr int nbBasicType()
Number of base type elements.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of base type elements.
static constexpr int nbBasicType()
Number of base type elements.
static constexpr eBasicDataType basicDataType()
Base data type.
static constexpr int nbBasicType()
Number of elements of the base type.
static constexpr eBasicDataType basicDataType()
Base data type.
Unicode character string.
Information characterizing a variable.
Integer dimension() const
Dimension.
Information characterizing the type of a variable.
-- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature --
Int32 Integer
Type representing an integer.
eBasicDataType
Type of a basic data item.
@ Unknown
Unknown or uninitialized data type.
eItemKind
Mesh entity type.
@ IK_Particle
Particle mesh entity.
@ IK_Node
Node mesh entity.
@ IK_Cell
Cell mesh entity.
@ IK_Unknown
Unknown or uninitialized mesh entity.
@ IK_Face
Face mesh entity.
@ IK_DoF
Degree of Freedom mesh entity.
@ IK_Edge
Edge mesh entity.
@ DT_Float32
'Float32' data type
@ DT_Real2x2
2x2 tensor data type
@ DT_Int16
16-bit integer data type
@ DT_Int8
8-bit integer data type
@ DT_Real3x3
3x3 tensor data type
@ DT_Int32
32-bit integer data type
@ DT_Real3
Vector 3 data type.
@ DT_Float16
'Float16' data type
@ DT_Int64
64-bit integer data type
@ DT_Unknown
Unknown or uninitialized data type.
@ DT_String
UTF-8 character string data type.
@ DT_BFloat16
'BFloat16' data type
@ DT_Real2
Vector 2 data type.