Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members

scim_exception.h

Go to the documentation of this file.
00001 /** 00002 * @file scim_exception.h 00003 * @brief Defines the scim::Exception class. 00004 */ 00005 00006 /* 00007 * Smart Common Input Method 00008 * 00009 * Copyright (c) 2004 James Su <suzhe@turbolinux.com.cn> 00010 * Copyright (c) 2003 James Su <suzhe@turbolinux.com.cn> 00011 * Copyright (c) 2002 James Su <suzhe@turbolinux.com.cn> 00012 * 00013 * 00014 * This library is free software; you can redistribute it and/or 00015 * modify it under the terms of the GNU Lesser General Public 00016 * License as published by the Free Software Foundation; either 00017 * version 2 of the License, or (at your option) any later version. 00018 * 00019 * This library is distributed in the hope that it will be useful, 00020 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00021 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00022 * GNU Lesser General Public License for more details. 00023 * 00024 * You should have received a copy of the GNU Lesser General Public 00025 * License along with this program; if not, write to the 00026 * Free Software Foundation, Inc., 59 Temple Place, Suite 330, 00027 * Boston, MA 02111-1307 USA 00028 * 00029 * $Id: scim_exception.h,v 1.7 2004/02/06 07:53:15 suzhe Exp $ 00030 */ 00031 00032 #ifndef __SCIM_EXCEPTION_H 00033 #define __SCIM_EXCEPTION_H 00034 00035 namespace scim { 00036 /** 00037 * @addtogroup Helper 00038 * @{ 00039 */ 00040 00041 /** 00042 * @brief A base class of all other exception classes. 00043 * 00044 * All other exception classes in namespace scim 00045 * should be derived from this class. 00046 */ 00047 class Exception: public std::exception 00048 { 00049 String m_what; 00050 public: 00051 Exception (const String& what_arg) : m_what (what_arg) { } 00052 ~Exception () throw () {} 00053 virtual const char* what () const throw () { return m_what.c_str (); } 00054 }; 00055 00056 /** @} */ 00057 00058 } // namespace scim 00059 00060 #endif //__SCIM_EXCEPTION_H 00061 /* 00062 vi:ts=4:nowrap:ai:expandtab 00063 */

Generated on Thu Dec 30 21:03:18 2004 for scim by doxygen 1.3.8