source: trunk/c++_tools/utility/Exception.h @ 648

Last change on this file since 648 was 648, checked in by Peter, 17 years ago

fixes #133 removed all errors reported from Doxygen. Only one error left which says Index is not documented but I don't want it to be documented actually we use the Doxygens preprocessor to skip documenting that class, yet Doxygen complains that class is not documented huh. Only solution would be to move that class to its own file and not keep it together with SVM.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 1.5 KB
Line 
1// $Id: Exception.h 648 2006-09-14 03:04:17Z peter $
2
3/*
4  Copyright (C) 2005 Jari Häkkinen, Peter Johansson
5  Copyright (C) 2006 Jari Häkkinen
6
7  This file is part of the thep c++ tools library,
8                                http://lev.thep.lu.se/trac/c++_tools
9
10  The c++ tools library is free software; you can redistribute it
11  and/or modify it under the terms of the GNU General Public License
12  as published by the Free Software Foundation; either version 2 of
13  the License, or (at your option) any later version.
14
15  The c++ tools library is distributed in the hope that it will be
16  useful, but WITHOUT ANY WARRANTY; without even the implied warranty
17  of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
18  General Public License for more details.
19
20  You should have received a copy of the GNU General Public License
21  along with this program; if not, write to the Free Software
22  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
23  02111-1307, USA.
24*/
25
26#ifndef _theplu_utility_exception_
27#define _theplu_utility_exception_
28
29#include <stdexcept>
30#include <string>
31
32namespace theplu {
33namespace utility {
34
35  ///
36  /// @brief Class for IO errors
37  ///
38  class IO_error : public std::runtime_error
39  {
40  public:
41    ///
42    /// Default constructor
43    ///
44    IO_error(void) throw() : std::runtime_error("IO_error:") {}
45
46    ///
47    /// Constructor for exception with message
48    ///
49    IO_error(std::string message) throw()
50      : std::runtime_error("IO_error: " + message) {}
51  };
52
53
54}} // of namespace utility and namespace theplu
55
56#endif
57
58
Note: See TracBrowser for help on using the repository browser.