1 #ifndef FCOLLEXCEPTIONS_H
2 #define FCOLLEXCEPTIONS_H
4 #include "zipios++/zipios-config.h"
12 using std::exception ;
14 /** An IOException is used to signal an I/O error.
16 class IOException : public exception {
18 IOException() throw () ;
19 explicit IOException( const string &msg ) throw () ;
20 IOException( const IOException &src ) throw () ;
21 IOException &operator= ( const IOException &src ) throw () ;
23 virtual const char *what() const throw () ;
24 virtual ~IOException() throw () ;
29 /** An FCollException is used to signal a problem with a
31 class FCollException : public exception {
33 FCollException() throw () ;
34 explicit FCollException( const string &msg ) throw () ;
35 FCollException( const FCollException &src ) throw () ;
36 FCollException &operator= ( const FCollException &src ) throw () ;
38 virtual const char *what() const throw () ;
39 virtual ~FCollException() throw () ;
44 /** An object member function may throw this exception, if the
45 operation it normally performs is inappropriate or impossible to
46 perform because of the current state of the object. */
47 class InvalidStateException : public exception {
49 InvalidStateException() throw () ;
50 explicit InvalidStateException( const string &msg ) throw () ;
51 InvalidStateException( const InvalidStateException &src ) throw () ;
52 InvalidStateException &operator= ( const InvalidStateException &src ) throw () ;
54 virtual const char *what() const throw () ;
55 virtual ~InvalidStateException() throw () ;
60 /** Basic exception */
61 class Exception : public exception {
63 Exception() throw () ;
64 explicit Exception( const string &msg ) throw () ;
65 Exception( const Exception &src ) throw () ;
66 Exception &operator= ( const Exception &src ) throw () ;
68 virtual const char *what() const throw () ;
69 virtual ~Exception() throw () ;
79 Header file that defines a number of exceptions used by FileCollection and
84 Zipios++ - a small C++ library that provides easy access to .zip files.
85 Copyright (C) 2000 Thomas Søndergaard
87 This library is free software; you can redistribute it and/or
88 modify it under the terms of the GNU Lesser General Public
89 License as published by the Free Software Foundation; either
90 version 2 of the License, or (at your option) any later version.
92 This library is distributed in the hope that it will be useful,
93 but WITHOUT ANY WARRANTY; without even the implied warranty of
94 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
95 Lesser General Public License for more details.
97 You should have received a copy of the GNU Lesser General Public
98 License along with this library; if not, write to the Free Software
99 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA