CVC3

smtlib_exception.h

Go to the documentation of this file.
00001 /*****************************************************************************/
00002 /*!
00003  * \file smtlib_exception.h
00004  * \brief An exception to be thrown by the smtlib translator.
00005  * 
00006  * Author: Clark Barrett
00007  * 
00008  * Created: Thu Feb 24 18:22:18 2005
00009  *
00010  * <hr>
00011  *
00012  * License to use, copy, modify, sell and/or distribute this software
00013  * and its documentation for any purpose is hereby granted without
00014  * royalty, subject to the terms and conditions defined in the \ref
00015  * LICENSE file provided with this distribution.
00016  * 
00017  * <hr>
00018  * 
00019  */
00020 /*****************************************************************************/
00021 
00022 #ifndef _cvc3__smtlib_exception_h_
00023 #define _cvc3__smtlib_exception_h_
00024 
00025 #include <string>
00026 #include <iostream>
00027 #include "exception.h"
00028 
00029 namespace CVC3 {
00030 
00031   class SmtlibException: public Exception {
00032   public:
00033     // Constructors
00034     SmtlibException() { }
00035     SmtlibException(const std::string& msg): Exception(msg) { }
00036     SmtlibException(const char* msg): Exception(msg) { }
00037     // Destructor
00038     virtual ~SmtlibException() { }
00039     virtual std::string toString() const {
00040       return "SMTLIB translation error: " + d_msg;
00041     }
00042   }; // end of class SmtlibException
00043 } // end of namespace CVC3 
00044 
00045 #endif