14#include "arcane/utils/ArgumentException.h"
16#include "arcane/core/IMesh.h"
18#include "arcane/materials/MeshBlock.h"
19#include "arcane/materials/IMeshMaterialMng.h"
20#include "arcane/materials/MatItemEnumerator.h"
33: TraceAccessor(mm->traceMng())
37, m_cells(info.cells())
38, m_environments(info.environments())
56 return m_material_mng->view(m_cells);
71 if (m_environments.contains(env))
73 String::format(
"environment {0} already in block {1}",
74 env->
name(), this->name()));
75 m_environments.add(env);
91 for (
Integer i = 0, n = m_environments.size(); i < n; ++i)
92 if (m_environments[i] == env) {
98 String::format(
"environment {0} not in block {1}",
99 env->
name(), this->name()));
100 m_environments.remove(index);
Exception when an argument is invalid.
virtual String name() const =0
Component name.
Interface of a mesh environment.
Interface for the material and environment manager of a mesh.
Brief: Information for the creation of a block.
Always enables tracing in Arcane parts concerning materials.
Int32 Integer
Type representing an integer.
std::int32_t Int32
Signed integer type of 32 bits.