ITK
4.1.0
Insight Segmentation and Registration Toolkit
|
00001 /*========================================================================= 00002 * 00003 * Copyright Insight Software Consortium 00004 * 00005 * Licensed under the Apache License, Version 2.0 (the "License"); 00006 * you may not use this file except in compliance with the License. 00007 * You may obtain a copy of the License at 00008 * 00009 * http://www.apache.org/licenses/LICENSE-2.0.txt 00010 * 00011 * Unless required by applicable law or agreed to in writing, software 00012 * distributed under the License is distributed on an "AS IS" BASIS, 00013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00014 * See the License for the specific language governing permissions and 00015 * limitations under the License. 00016 * 00017 *=========================================================================*/ 00018 #ifndef __itkFEMException_h 00019 #define __itkFEMException_h 00020 00021 #include <typeinfo> 00022 #include <string> 00023 00024 #include "itkMacro.h" 00025 00026 namespace itk 00027 { 00028 namespace fem 00029 { 00041 class ITK_ABI_EXPORT FEMException : public itk::ExceptionObject 00042 { 00043 public: 00044 00053 FEMException(const char *file, unsigned int lineNumber, std::string location = "Unknown"); 00054 00056 virtual ~FEMException() 00057 throw ( ) 00058 { 00059 } 00060 00062 itkTypeMacro(FEMException, ExceptionObject); 00063 }; 00064 00072 class ITK_ABI_EXPORT FEMExceptionIO : public FEMException 00073 { 00074 public: 00075 00081 FEMExceptionIO(const char *file, unsigned int lineNumber, std::string location, std::string moreDescription); 00082 00084 virtual ~FEMExceptionIO() 00085 throw ( ) 00086 { 00087 } 00088 00090 itkTypeMacro(FEMExceptionIO, FEMException); 00091 }; 00092 00111 class ITK_ABI_EXPORT FEMExceptionWrongClass : public FEMException 00112 { 00113 public: 00114 FEMExceptionWrongClass(const char *file, unsigned int lineNumber, std::string location); 00115 00117 virtual ~FEMExceptionWrongClass() 00118 throw ( ) 00119 { 00120 } 00121 00123 itkTypeMacro(FEMExceptionWrongClass, FEMException); 00124 }; 00125 00134 class ITK_ABI_EXPORT FEMExceptionObjectNotFound : public FEMException 00135 { 00136 public: 00137 FEMExceptionObjectNotFound(const char *file, unsigned int lineNumber, std::string location, std::string baseClassName, 00138 int GN); 00139 00141 virtual ~FEMExceptionObjectNotFound() 00142 throw ( ) 00143 { 00144 } 00145 00147 itkTypeMacro(FEMExceptionObjectNotFound, FEMException); 00148 00152 std::string m_baseClassName; 00153 int m_GlobalNumber; 00154 }; 00155 00164 class ITK_ABI_EXPORT FEMExceptionSolution : public FEMException 00165 { 00166 public: 00167 00173 FEMExceptionSolution(const char *file, unsigned int lineNumber, std::string location, std::string moreDescription); 00174 00176 virtual ~FEMExceptionSolution() 00177 throw ( ) 00178 { 00179 } 00180 00182 itkTypeMacro(FEMExceptionSolution, FEMException); 00183 }; 00184 } 00185 } // end namespace itk::fem 00186 00187 #endif // #ifndef __itkFEMException_h 00188