00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef TOOL_EXCEPTIONS_HH_
00023 # define TOOL_EXCEPTIONS_HH_
00024
00025 # include <stdexcept>
00026 # include <string>
00027
00028 namespace tool
00029 {
00030
00032 struct user_interruption: public std::runtime_error
00033 {
00034 user_interruption(const std::string&);
00035 };
00036
00038 struct file_error: public std::runtime_error
00039 {
00040 file_error(const std::string&);
00041 };
00042
00044 struct read_error: public file_error
00045 {
00046 read_error(const std::string&);
00047 };
00048
00050 struct write_error: public file_error
00051 {
00052 write_error(const std::string&);
00053 };
00054
00056 struct seek_error: public file_error
00057 {
00058 seek_error(const std::string&);
00059 };
00060
00062 struct bad_file: public file_error
00063 {
00064 bad_file(const std::string&);
00065 };
00066
00067 }
00068
00069 # include "exceptions.hxx"
00070
00071 #endif // ! TOOL_EXCEPTIONS_HH_