Arcane  v3.14.10.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
GoBackwardException.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/* GoBackwardException.cc (C) 2000-2015 */
9/* */
10/* Exception pour demander un retour-arrière de la boucle en temps */
11/*---------------------------------------------------------------------------*/
12/*---------------------------------------------------------------------------*/
13
14#include "arcane/utils/ArcanePrecomp.h"
15
16#include "arcane/utils/String.h"
17#include "arcane/utils/Iostream.h"
18#include "arcane/utils/GoBackwardException.h"
19
20/*---------------------------------------------------------------------------*/
21/*---------------------------------------------------------------------------*/
22
23ARCANE_BEGIN_NAMESPACE
24
25/*---------------------------------------------------------------------------*/
26/*---------------------------------------------------------------------------*/
27
28GoBackwardException::
29GoBackwardException(const String& where)
30: Exception("GoBackward",where)
31{
32}
33
34/*---------------------------------------------------------------------------*/
35/*---------------------------------------------------------------------------*/
36
37GoBackwardException::
38GoBackwardException(const String& where,const String& message)
39: Exception("GoBackward",where)
40, m_message(message)
41{
42}
43
44/*---------------------------------------------------------------------------*/
45/*---------------------------------------------------------------------------*/
46
47GoBackwardException::
48GoBackwardException(const TraceInfo& where)
49: Exception("GoBackward",where)
50{
51}
52
53/*---------------------------------------------------------------------------*/
54/*---------------------------------------------------------------------------*/
55
56GoBackwardException::
57GoBackwardException(const TraceInfo& where,const String& message)
58: Exception("GoBackward",where)
59, m_message(message)
60{
61}
62
63/*---------------------------------------------------------------------------*/
64/*---------------------------------------------------------------------------*/
65
66void GoBackwardException::
67explain(std::ostream& m) const
68{
69 m << "Go backward.";
70 if (!m_message.null())
71 m << "Message: " << m_message << '\n';
72}
73
74/*---------------------------------------------------------------------------*/
75/*---------------------------------------------------------------------------*/
76
77ARCANE_END_NAMESPACE
78
79/*---------------------------------------------------------------------------*/
80/*---------------------------------------------------------------------------*/
81