/usr/include/openturns/exceptions.h is in libopenturns-dev 0.15-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 | /**********************************************************************
* Author: Leo Liberti *
* Name: exceptions.h *
* Source: GNU C++ *
* Purpose: Expression v3 exceptions *
* History: 010622 0.0 work started *
* License: (C) Leo Liberti, all rights reserved. Code published under the
Common Public License.
***********************************************************************/
#ifndef __EV3EXCEPTIONSH__
#define __EV3EXCEPTIONSH__
#include <string>
#include <iostream>
#define RCS8 "$Id: exceptions.h,v 1.5 2003/10/08 11:13:58 liberti Exp liberti $"
#define HELPURL "http://liberti.dhs.org/"
#define NONE "[none]"
#define STDACTION std::cerr << interface_ << "::" << scope_ << ": in [" << operation_ << "]: " << description_ << ", code = " << code_ << ", see " << moreinfo_ << std::endl
namespace Ev3 {
class ErrBase {
public:
unsigned long code_;
std::string interface_;
std::string scope_;
std::string operation_;
std::string description_;
std::string moreinfo_;
ErrBase() :
code_(0),
interface_(NONE),
scope_(NONE),
operation_(NONE),
description_(NONE),
moreinfo_(HELPURL)
{
STDACTION;
}
ErrBase(const unsigned long mycode,
const std::string & myif,
const std::string & myscope,
const std::string & myop,
const std::string & mydesc,
const std::string & myinfo) :
code_(mycode),
interface_(myif),
scope_(myscope),
operation_(myop),
description_(mydesc),
moreinfo_(myinfo)
{
STDACTION;
}
};
class ErrUnknown : public ErrBase
{
public:
ErrUnknown(const unsigned long mycode,
const std::string & myif,
const std::string & myscope,
const std::string & myop,
const std::string & mydesc,
const std::string & myinfo) :
ErrBase(mycode, myif, myscope, myop, mydesc, myinfo)
{
STDACTION;
}
};
class ErrNotPermitted : public ErrBase
{
public:
ErrNotPermitted(const unsigned long mycode,
const std::string & myif,
const std::string & myscope,
const std::string & myop,
const std::string & mydesc,
const std::string & myinfo) :
ErrBase(mycode, myif, myscope, myop, mydesc, myinfo)
{
STDACTION;
}
};
class ErrDivideByZero : public ErrBase
{
public:
std::string dividend;
ErrDivideByZero(const unsigned long mycode,
const std::string & myif,
const std::string & myscope,
const std::string & myop,
const std::string & mydesc,
const std::string & myinfo,
const std::string & mydiv) :
ErrBase(mycode, myif, myscope, myop, mydesc, myinfo),
dividend(mydiv)
{
STDACTION;
}
};
} /* namespace Ev3 */
#endif /* __EV3EXCEPTIONSH__ */
|