12#ifndef ARCANE_MATERIALS_INTERNAL_MESHMATERIAL_H
13#define ARCANE_MATERIALS_INTERNAL_MESHMATERIAL_H
17#include "arcane/utils/TraceAccessor.h"
19#include "arcane/core/ItemGroup.h"
20#include "arcane/core/materials/IMeshMaterial.h"
21#include "arcane/core/materials/MatItem.h"
22#include "arcane/core/materials/internal/IMeshComponentInternal.h"
24#include "arcane/materials/internal/MeshComponentData.h"
25#include "arcane/materials/internal/MeshMaterialVariableIndexer.h"
60 explicit InternalApi(MeshMaterial* mat)
68 return m_material->variableIndexer();
72 return m_material->constituentItemListView();
80 MeshMaterial* m_material =
nullptr;
99 return m_data.variableIndexer();
104 return m_data.constituentItemListView();
107 Int32 id()
const override {
return m_data.componentId(); }
136 m_data.setSpecificExecutionPolicy(policy);
140 return m_data.specificExecutionPolicy();
151 m_data._setConstituentItem(index,
id);
153 Int16 componentId()
const {
return m_data.componentId(); }
160 void resizeItemsInternal(
Integer nb_item);
161 MeshComponentData* componentData() {
return &m_data; }
162 MeshEnvironment* trueEnvironment() {
return m_environment; }
163 const MeshEnvironment* trueEnvironment()
const {
return m_environment; }
168 IMeshMaterialMng* m_material_mng =
nullptr;
169 MeshMaterialInfo* m_infos =
nullptr;
170 MeshEnvironment* m_environment =
nullptr;
171 IUserMeshMaterial* m_user_material =
nullptr;
172 MeshComponentData m_data;
173 MeshMaterial* m_non_const_this =
nullptr;
Arcane cell with material and environment information.
View over the impure part of a component.
View over a vector of entities of a component.
View over pure or partial entities of a component.
View over the pure part of a component.
Index of a constituent entity in the list of constituent entities.
View of a ConstituentItemLocalIdList instance.
Arcane internal API for 'IMeshComponent'.
Interface of a mesh environment.
Interface for the material and environment manager of a mesh.
Interface of a user material.
Represents a material in a multi-material cell.
View over the impure part of the entities of a material.
View over a vector of entities of a material.
View over pure or partial entities of a material.
View over the pure part of the entities of a material.
Info about a material of a mesh.
Indexer for material variables.
ConstituentItemLocalIdListView constituentItemListView() const override
View of the constituent cells.
Ref< IConstituentItemVectorImpl > createItemVectorImpl() const override
Create an instance of the 'ConstituentItemVectorImpl' implementation.
MeshMaterialVariableIndexer * variableIndexer() const override
Indexer to access partial variables.
Int32 variableIndexerIndex() const override
Index to access partial variables.
void build()
Public functions but reserved for IMeshMaterialMng.
Int32 id() const override
Component identifier.
IMeshEnvironment * environment() const override
Environment to which this material belongs.
void setSpecificExecutionPolicy(Accelerator::eExecutionPolicy policy) override
Sets an execution policy for this constituent.
bool hasSpace(MatVarSpace space) const override
Indicates if the component is defined for space space.
MatItemVectorView matView() const override
View associated with this material.
ComponentImpurePartItemVectorView impureItems() const override
View on the list of impure (partial) entities of the component.
Accelerator::eExecutionPolicy specificExecutionPolicy() const override
Specific execution policy.
MatCell findMatCell(AllEnvCell c) const override
Cell of this material for cell c.
IMeshComponentInternal * _internalApi() override
Internal API.
bool isMaterial() const override
True if the component is a material.
ComponentPurePartItemVectorView pureItems() const override
View on the list of pure entities (associated with the global cell) of the component.
ComponentItemVectorView view() const override
View associated with this component.
ComponentCell findComponentCell(AllEnvCell c) const override
Cell of this component for cell c.
IMeshEnvironment * asEnvironment() override
Returns the component in the form of an IMeshMaterial.
IMeshMaterialMng * materialMng() override
Associated manager.
ComponentPartItemVectorView partItems(eMatPart part) const override
View on the pure or impure part of the component's entities.
MatPurePartItemVectorView pureMatItems() const override
View on the list of pure entities (associated with the global cell) of the material.
String name() const override
Component name.
void checkValid() override
Checks that the component is valid.
MatPartItemVectorView partMatItems(eMatPart part) const override
View on the pure or impure part of the material entities.
void setUserMaterial(IUserMeshMaterial *umm) override
Sets the associated user material.
MeshMaterialInfo * infos() const override
Material information.
MatImpurePartItemVectorView impureMatItems() const override
View on the list of impure (partial) entities of the material.
IUserMeshMaterial * userMaterial() const override
Associated user material.
IMeshMaterial * asMaterial() override
Returns the component in the form of an IMeshMaterial.
ITraceMng * traceMng() override
Associated trace manager.
CellGroup cells() const override
Group of cells for this material.
bool isEnvironment() const override
True if the component is an environment.
Reference to an instance.
Unicode character string.
TraceAccessor(ITraceMng *m)
Constructs an accessor via the trace manager m.
ITraceMng * traceMng() const
Trace manager.
ItemGroupT< Cell > CellGroup
Group of cells.
eExecutionPolicy
Execution policy for a Runner.
Always enables tracing in Arcane parts concerning materials.
MatVarSpace
Definition space for a material variable.
@ MaterialAndEnvironment
Variable having values on environments and materials.
eMatPart
Part of a component.
Int32 Integer
Type representing an integer.
std::int16_t Int16
Signed integer type of 16 bits.
std::int32_t Int32
Signed integer type of 32 bits.