12#ifndef ARCANE_MATERIALS_INTERNAL_MATERIALMODIFIEROPERATION_H
13#define ARCANE_MATERIALS_INTERNAL_MATERIALMODIFIEROPERATION_H
17#include "arcane/utils/Array.h"
18#include "arcane/utils/NumArray.h"
21#include "arcane/materials/internal/MeshMaterialModifierImpl.h"
35class MaterialModifierOperation
39 MaterialModifierOperation();
49 return new MaterialModifierOperation(mat,
ids,
true);
53 return new MaterialModifierOperation(mat,
ids,
false);
59 bool isAdd()
const {
return m_is_add; }
89 bool m_is_add =
false;
Interface of a mesh material.
Operation to add or remove cells from a material.
IMeshMaterial * material() const
The material for which cells are to be added/removed.
bool isAdd() const
Indicates whether the operation is to add or remove cells from the material.
static Int32 _checkMaterialPresence(MaterialModifierOperation *operation)
Checks if the cells ids are already in the material mat.
static void _filterValidIds(MaterialModifierOperation *operation, Int32Array &valid_ids)
Filters the array of cells ids so that it is valid.
void filterIds()
Filters the cell IDs.
SmallSpan< const Int32 > ids() const
List of localId() of cells to add/remove.
View of an array of elements of type T.
1D data vector with value semantics (STL style).
Always enables tracing in Arcane parts concerning materials.
Array< Int32 > Int32Array
Dynamic one-dimensional array of 32-bit integers.
std::int32_t Int32
Signed integer type of 32 bits.