Arcane  4.1.12.0
Developer documentation
Loading...
Searching...
No Matches
TiedInterfaceExchanger.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/* TiedInterfaceExchanger.h (C) 2000-2016 */
9/* */
10/* Exchanger between sub-domains of linked interfaces. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_MESH_TIEDINTERFACEEXCHANGER_H
13#define ARCANE_MESH_TIEDINTERFACEEXCHANGER_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
17#include "arcane/utils/TraceAccessor.h"
18
19#include "arcane/mesh/MeshGlobal.h"
20
21#include "arcane/core/ItemInternalVectorView.h"
22#include "arcane/core/IItemFamilySerializeStep.h"
23
24#include <map>
25
26/*---------------------------------------------------------------------------*/
27/*---------------------------------------------------------------------------*/
28
29namespace Arcane
30{
31class ISubDomain;
33} // namespace Arcane
34
35/*---------------------------------------------------------------------------*/
36/*---------------------------------------------------------------------------*/
37
38namespace Arcane::mesh
39{
40
41/*---------------------------------------------------------------------------*/
42/*---------------------------------------------------------------------------*/
43
44class DynamicMesh;
45
46/*---------------------------------------------------------------------------*/
47/*---------------------------------------------------------------------------*/
48
66class TiedInterfaceExchanger
67: public TraceAccessor
69{
70 class OneSubDomainInfo;
71 class DeserializedInfo;
72
73 public:
74
75 TiedInterfaceExchanger(DynamicMesh* mesh);
76 ~TiedInterfaceExchanger();
77
78 public:
79
80 void initialize() override;
81 void notifyAction(const NotifyActionArgs&) override {}
82 void serialize(const ItemFamilySerializeArgs& args) override;
83 void finalize() override;
84 IItemFamily* family() const override;
85 ePhase phase() const override { return IItemFamilySerializeStep::PH_Item; }
86
87 private:
88
89 DynamicMesh* m_mesh;
90 ISubDomain* m_sub_domain;
91 DeserializedInfo* m_deserialized_info;
92 Int32 m_my_rank;
93 typedef std::map<Int32, OneSubDomainInfo*> SubDomainInfoMap;
94 SubDomainInfoMap m_infos;
95
96 private:
97
98 inline OneSubDomainInfo* _getInfo(Int32 rank);
99};
100
101/*---------------------------------------------------------------------------*/
102/*---------------------------------------------------------------------------*/
103
104} // namespace Arcane::mesh
105
106/*---------------------------------------------------------------------------*/
107/*---------------------------------------------------------------------------*/
108
109#endif
Interface for a step in the serialization of entity families.
Interface of an entity family.
Definition IItemFamily.h:83
Interface of the subdomain manager.
Definition ISubDomain.h:75
Arguments for the serialization callbacks of entity families.
TraceAccessor(ITraceMng *m)
Constructs an accessor via the trace manager m.
Implementation of a mesh.
Definition DynamicMesh.h:98
void notifyAction(const NotifyActionArgs &) override
Notifies the instance that we are entering a certain phase of the exchange.
IItemFamily * family() const override
Associated family.
void initialize() override
Initializes the instance before the start of exchanges.
void serialize(const ItemFamilySerializeArgs &args) override
Serializes the faces into the buffer buf.
ePhase phase() const override
Serialization phase where this instance is involved.
void finalize() override
Performs end-of-exchange processing.
-- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature --
std::int32_t Int32
Signed integer type of 32 bits.