Arcane  4.1.12.0
Developer documentation
Loading...
Searching...
No Matches
MeshMaterialVariableFactoryRegisterer.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2026 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
4// See the top-level COPYRIGHT file for details.
5// SPDX-License-Identifier: Apache-2.0
6//-----------------------------------------------------------------------------
7/*---------------------------------------------------------------------------*/
8/* MeshMaterialVariableFactoryRegisterer.h (C) 2000-2022 */
9/* */
10/* Singleton allowing registration of a material variable factory. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_MATERIALS_MESHMATERIALVARIABLEFACTORYREGISTERER_H
13#define ARCANE_MATERIALS_MESHMATERIALVARIABLEFACTORYREGISTERER_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
17#include "arcane/utils/GenericRegisterer.h"
18
19#include "arcane/core/materials/MaterialVariableTypeInfo.h"
20
22
23/*---------------------------------------------------------------------------*/
24/*---------------------------------------------------------------------------*/
25
26namespace Arcane::Materials
27{
28
29/*---------------------------------------------------------------------------*/
30/*---------------------------------------------------------------------------*/
31
37: public GenericRegisterer<MeshMaterialVariableFactoryRegisterer>
38{
39 public:
40
42 static BaseInfo& registererInfo();
43
44 using MeshMaterialVariableFactoryFunc = MeshMaterialVariableFactoryVariableRefCreateFunc;
45
46 public:
47
49 MeshMaterialVariableFactoryRegisterer(MeshMaterialVariableFactoryFunc func,
50 const MaterialVariableTypeInfo& var_type_info)
51 : m_function(func)
52 , m_variable_type_info(var_type_info)
53 {}
54
55 public:
56
59
62
63 private:
64
66 MeshMaterialVariableFactoryFunc m_function;
67
70
71 private:
72
73 static BaseInfo m_global_infos;
74};
75
76/*---------------------------------------------------------------------------*/
77/*---------------------------------------------------------------------------*/
78
79} // namespace Arcane::Materials
80
81/*---------------------------------------------------------------------------*/
82/*---------------------------------------------------------------------------*/
83
84#endif
Information characterizing the type of a material variable.
MeshMaterialVariableFactoryFunc m_function
Creation function of the IMeshMaterialVariableFactoryFactory.
MeshMaterialVariableFactoryRegisterer(MeshMaterialVariableFactoryFunc func, const MaterialVariableTypeInfo &var_type_info)
Creates a registerer for a MeshMaterialVariableFactory for the type var_type_info and for the creatio...
const MaterialVariableTypeInfo & variableTypeInfo() const
Information about the variable type.
MaterialVariableTypeInfo m_variable_type_info
Information about the variable type.
Reference to an instance.
Always enables tracing in Arcane parts concerning materials.
class ARCANE_MATERIALS_EXPORT(64) SimdMatVarIndex
SIMD indexer on a component.