ccsoft  0.0.0
Convolutional codes library with soft decision decoding
/shared/development/google_code/rssoft/libccsoft/lib/CCSoft_Exception.h
Go to the documentation of this file.
00001 /*
00002      Copyright 2013 Edouard Griffiths <f4exb at free dot fr>
00003 
00004      This file is part of CCSoft. A Convolutional Codes Soft Decoding library
00005 
00006      This program is free software; you can redistribute it and/or modify
00007      it under the terms of the GNU General Public License as published by
00008      the Free Software Foundation; either version 2 of the License, or
00009      (at your option) any later version.
00010 
00011      This program is distributed in the hope that it will be useful,
00012      but WITHOUT ANY WARRANTY; without even the implied warranty of
00013      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014      GNU General Public License for more details.
00015 
00016      You should have received a copy of the GNU General Public License
00017      along with this program; if not, write to the Free Software
00018      Foundation, Inc., 51 Franklin Street, Boston, MA  02110-1301  USA
00019 
00020      Exception for CC Soft related procedures
00021 
00022 */
00023 #ifndef __CCSOFT_EXCEPTION_H__
00024 #define __CCSOFT_EXCEPTION_H__
00025 
00026 #include <string>
00027 
00028 namespace ccsoft
00029 {
00030 
00034     class CCSoft_Exception : public std::exception
00035     {
00036     public:
00041         CCSoft_Exception(std::string strError) : _error_msg(strError)
00042         {}
00043         virtual ~CCSoft_Exception() throw()
00044         {}
00049         virtual const char* what() const throw()
00050         {
00051             return _error_msg.c_str();
00052         }
00053 
00054     protected:
00055         std::string _error_msg; 
00056 
00057     private:
00061         CCSoft_Exception()
00062         {};
00063     };
00064 } // namespace ccsoft
00065 
00066 #endif // __CCSOFT_EXCEPTION_H__
 All Classes Namespaces Files Functions Variables Typedefs Friends Defines