00001 00002 /*************************************************************************** 00003 * Copyright (C) 2007 Eddie * 00004 * * 00005 * This file is part of fastcgi++. * 00006 * * 00007 * fastcgi++ is free software: you can redistribute it and/or modify it * 00008 * under the terms of the GNU Lesser General Public License as published * 00009 * by the Free Software Foundation, either version 3 of the License, or (at * 00010 * your option) any later version. * 00011 * * 00012 * fastcgi++ is distributed in the hope that it will be useful, but WITHOUT * 00013 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * 00014 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public * 00015 * License for more details. * 00016 * * 00017 * You should have received a copy of the GNU Lesser General Public License * 00018 * along with fastcgi++. If not, see <http://www.gnu.org/licenses/>. * 00019 ****************************************************************************/ 00020 00021 00022 #ifndef EXCEPTIONS_HPP 00023 #define EXCEPTIONS_HPP 00024 00025 #include <exception> 00026 00028 namespace Fastcgipp 00029 { 00031 namespace Exceptions 00032 { 00034 class FastcgiException: public std::exception 00035 { 00036 public: 00037 FastcgiException(const char* msg_): msg(msg_) { } 00038 00039 virtual const char* what() const throw() 00040 { 00041 return msg; 00042 } 00043 private: 00044 const char* const msg; 00045 }; 00046 } 00047 } 00048 00049 #endif