/* SetException.H Definition of exception for use with Sets Mitch Edelman Created: 31 August 2000 Current: 2 September 2000 */ #ifndef SETEXCEPTION_H #define SETEXCEPTION_H #include "string.H" // SetException class // An exception for use with Sets. // The exception holds an associated error message // that can be retrieved by the method errorMsg. class SetException { public: // Constructor of no arguments // Produces empty message SetException(); // Constructor // Param errorMsg is the associated message SetException(const string & errorMsg); // Copy constructor // se is the SetException to be copied SetException(const SetException & se); // Destructor ~SetException(); // Assignment operator // se is the SetException to be assigned (the rhs) const SetException & operator=(const SetException & se); // errorMsg // Accessor for the associated message // Returns the associated message const string & errorMsg() const; private: string _msg; }; #endif