Arcane  4.1.12.0
User documentation
Loading...
Searching...
No Matches
MeshPartInfo.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/* MeshPartInfo.h (C) 2000-2018 */
9/* */
10/* Mesh part information. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_MESHPARTINFO_H
13#define ARCANE_MESHPARTINFO_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
18
19/*---------------------------------------------------------------------------*/
20/*---------------------------------------------------------------------------*/
21
22namespace Arcane
23{
24
25class IParallelMng;
26
27/*---------------------------------------------------------------------------*/
28/*---------------------------------------------------------------------------*/
29
30/*!
31 * \brief Information about a partitioned mesh.
32 */
33class ARCANE_CORE_EXPORT MeshPartInfo
34{
35 public:
36
37 MeshPartInfo(Int32 part_rank, Int32 nb_part,
38 Int32 replication_rank, Int32 nb_replication)
39 : m_part_rank(part_rank)
40 , m_nb_part(nb_part)
41 , m_replication_rank(replication_rank)
42 , m_nb_replication(nb_replication)
43 {}
44 MeshPartInfo()
45 : m_part_rank(-1)
46 , m_nb_part(0)
47 , m_replication_rank(-1)
48 , m_nb_replication(0)
49 {}
50
51 public:
52
53 Int32 partRank() const { return m_part_rank; }
54 void setPartRank(Int32 v) { m_part_rank = v; }
55 Int32 nbPart() const { return m_nb_part; }
56 void setNbPart(Int32 v) { m_nb_part = v; }
57 Int32 replicationRank() const { return m_replication_rank; }
58 void setReplicationRank(Int32 v) { m_replication_rank = v; }
59 Int32 nbReplication() const { return m_nb_replication; }
60 void setNbReplication(Int32 v) { m_nb_replication = v; }
61
62 private:
63
64 Int32 m_part_rank;
65 Int32 m_nb_part;
66 Int32 m_replication_rank;
67 Int32 m_nb_replication;
68};
69
70/*---------------------------------------------------------------------------*/
71/*---------------------------------------------------------------------------*/
72
73extern "C++" ARCANE_CORE_EXPORT
75makeMeshPartInfoFromParallelMng(IParallelMng* pm);
76
77/*---------------------------------------------------------------------------*/
78/*---------------------------------------------------------------------------*/
79
80} // End namespace Arcane
81
82/*---------------------------------------------------------------------------*/
83/*---------------------------------------------------------------------------*/
84
85#endif
Arcane configuration file.
Interface of the parallelism manager for a subdomain.
Information about a partitioned mesh.
-- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature --
std::int32_t Int32
Signed integer type of 32 bits.