Arcane  v3.16.8.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
BadVariantTypeException.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2025 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/* BadVariantTypeException.h (C) 2000-2025 */
9/* */
10/* Exception levée lorsqu'un variant n'est pas du type souhaité */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_CORE_DATATYPE_BADVARIANTTYPEEXCEPTION_H
13#define ARCANE_CORE_DATATYPE_BADVARIANTTYPEEXCEPTION_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
17#include "arcane/utils/Exception.h"
18
19#include "arcane/core/datatype/VariantBase.h"
20
21/*---------------------------------------------------------------------------*/
22/*---------------------------------------------------------------------------*/
23
24namespace Arcane
25{
26
27/*---------------------------------------------------------------------------*/
28/*---------------------------------------------------------------------------*/
37class BadVariantTypeException
38: public Exception
39{
40 public:
41
42 BadVariantTypeException(const String& where,VariantBase::eType wrongType);
43
44 public:
45
46 virtual void explain(std::ostream& m) const;
47
48 private:
49
50 VariantBase::eType m_wrong_type;
51};
52
53/*---------------------------------------------------------------------------*/
54/*---------------------------------------------------------------------------*/
55
56}
57
58/*---------------------------------------------------------------------------*/
59/*---------------------------------------------------------------------------*/
60
61#endif
62
virtual void explain(std::ostream &m) const
Explique la cause de l'exception dans le flot o.
const String & where() const
Localisation de l'exception.
Exception(const String &name, const String &where)
Chaîne de caractères unicode.
-*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-