source: trunk/lib/utility/Exception.h @ 341

Last change on this file since 341 was 341, checked in by Jari Häkkinen, 18 years ago

Added exceptions for tracing file format problems when reading vectors.
Changed implentation for reading ints and doubles into stl vectors, now
unexpected characters are skipped instead of treated as zeros.
Some other minor things.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 435 bytes
Line 
1// $Id: Exception.h 341 2005-06-07 14:41:25Z jari $
2
3#ifndef _theplu_utility_exception_
4#define _theplu_utility_exception_
5
6#include <stdexcept>
7#include <string>
8
9namespace theplu {
10namespace utility {
11
12
13  class IO_error : public std::runtime_error
14  {
15  public:
16    IO_error(void) throw() : std::runtime_error("IO_error:") {}
17    IO_error(std::string& message) throw()
18      : std::runtime_error("IO_error: " + message) {}
19  };
20
21
22}} // of namespace utility and namespace theplu
23
24#endif
25
26
Note: See TracBrowser for help on using the repository browser.