ITK  4.3.0
Insight Segmentation and Registration Toolkit
itkFEMException.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __itkFEMException_h
19 #define __itkFEMException_h
20 
21 #include <typeinfo>
22 #include <string>
23 
24 #include "itkMacro.h"
25 
26 namespace itk
27 {
28 namespace fem
29 {
41 class ITK_ABI_EXPORT FEMException : public itk::ExceptionObject
42 {
43 public:
44 
53  FEMException(const char *file, unsigned int lineNumber, std::string location = "Unknown");
54 
56  virtual ~FEMException()
57  throw ( )
58  {
59  }
60 
62  itkTypeMacro(FEMException, ExceptionObject);
63 };
64 
72 class ITK_ABI_EXPORT FEMExceptionIO : public FEMException
73 {
74 public:
75 
81  FEMExceptionIO(const char *file, unsigned int lineNumber, std::string location, std::string moreDescription);
82 
84  virtual ~FEMExceptionIO()
85  throw ( )
86  {
87  }
88 
90  itkTypeMacro(FEMExceptionIO, FEMException);
91 };
92 
111 class ITK_ABI_EXPORT FEMExceptionWrongClass : public FEMException
112 {
113 public:
114  FEMExceptionWrongClass(const char *file, unsigned int lineNumber, std::string location);
115 
118  throw ( )
119  {
120  }
121 
123  itkTypeMacro(FEMExceptionWrongClass, FEMException);
124 };
125 
134 class ITK_ABI_EXPORT FEMExceptionObjectNotFound : public FEMException
135 {
136 public:
137  FEMExceptionObjectNotFound(const char *file, unsigned int lineNumber, std::string location, std::string baseClassName,
138  int GN);
139 
142  throw ( )
143  {
144  }
145 
148 
152  std::string m_baseClassName;
154 };
155 
164 class ITK_ABI_EXPORT FEMExceptionSolution : public FEMException
165 {
166 public:
167 
173  FEMExceptionSolution(const char *file, unsigned int lineNumber, std::string location, std::string moreDescription);
174 
177  throw ( )
178  {
179  }
180 
182  itkTypeMacro(FEMExceptionSolution, FEMException);
183 };
184 }
185 } // end namespace itk::fem
186 
187 #endif // #ifndef __itkFEMException_h
188