Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   Related Pages  

CipherExceptions.h

00001 /*
00002  * Copyright 2003 Michael A. Marsh, Cornell University. All rights reserved.
00003  * This software is released under the modified BSD license.
00004  * See the file LICENSE in the top-level directory for details.
00005  */
00006 //
00007 // $Id: CipherExceptions.h,v 1.3 2004/05/19 15:56:46 mmarsh Exp $
00008 //
00009 // $Log: CipherExceptions.h,v $
00010 // Revision 1.3  2004/05/19 15:56:46  mmarsh
00011 // *** empty log message ***
00012 //
00013 // Revision 1.2  2003/11/04 22:31:47  mmarsh
00014 // *** empty log message ***
00015 //
00016 //
00017 
00018 #ifndef __CODEX_CIPHERS_CIPHEREXCEPTIONS_H__
00019 #define __CODEX_CIPHERS_CIPHEREXCEPTIONS_H__
00020 
00021 #include <string>
00022 
00023 using namespace std;
00024 
00029 namespace CODEX_Ciphers
00030 {
00034    class ExceptionBase
00035    {
00036       public :
00042          ExceptionBase( const string& fname, int line ) :
00043             m_fname(fname),
00044             m_line(line)
00045          {}
00046 
00048          virtual ~ExceptionBase() {}
00049 
00053          void report() const;
00054 
00056          const string& fname() const { return m_fname; }
00057 
00059          int line() const { return m_line; }
00060 
00061       protected :
00066          virtual void derivedMsg() const = 0;
00067 
00068       private :
00069          string  m_fname;
00070          int     m_line;
00071    };
00072 
00073 }
00074 
00075 #endif /* __CODEX_CIPHERS_CIPHEREXCEPTIONS_H__ */

Generated on Wed Jun 2 16:32:54 2004 for COrnell Data EXchange (CODEX) by doxygen1.2.18