Arcane  v3.14.10.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
MessageId.cc
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2022 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/* MessageId.cc (C) 2000-2020 */
9/* */
10/* Identifiant d'un message point à point. */
11/*---------------------------------------------------------------------------*/
12/*---------------------------------------------------------------------------*/
13
14#include "arccore/message_passing/MessageId.h"
15
16#include <iostream>
17
18/*---------------------------------------------------------------------------*/
19/*---------------------------------------------------------------------------*/
20
21namespace Arccore
22{
23
24/*---------------------------------------------------------------------------*/
25/*---------------------------------------------------------------------------*/
26
27MessagePassing::MessageId::_Message MessagePassing::MessageId::null_message;
28
29/*---------------------------------------------------------------------------*/
30/*---------------------------------------------------------------------------*/
31
32void MessagePassing::MessageId::
33print(std::ostream& o) const
34{
35 o << "(id=";
36 if (m_type==T_Null)
37 o << "(null)";
38 else if (m_type==T_Int)
39 o << m_message.i;
40 else if (m_type==T_Long)
41 o << m_message.l;
42 else
43 o << m_message.cv;
44 o << ",source_rank=" << m_source_info.rank()
45 << " tag=" << m_source_info.tag()
46 << " size=" << m_source_info.size();
47}
48
49/*---------------------------------------------------------------------------*/
50/*---------------------------------------------------------------------------*/
51
52} // End namespace Arccore
53
54/*---------------------------------------------------------------------------*/
55/*---------------------------------------------------------------------------*/
MessageTag tag() const
Tag du message.
Int64 size() const
Taille du message.
MessageRank rank() const
Rang de la source.
Espace de nom de Arccore.
Definition ArcaneTypes.h:24