37 #ifndef PCL_EXCEPTIONS_H_ 38 #define PCL_EXCEPTIONS_H_ 42 #include <pcl/pcl_macros.h> 43 #include <boost/current_function.hpp> 50 #define PCL_THROW_EXCEPTION(ExceptionName, message) \ 52 std::ostringstream s; \ 55 throw ExceptionName(s.str(), __FILE__, BOOST_CURRENT_FUNCTION, __LINE__); \ 70 const std::string& file_name =
"",
71 const std::string& function_name =
"" ,
72 unsigned line_number = 0) throw ()
73 :
std::runtime_error (error_description)
106 std::stringstream sstream;
116 sstream <<
": " <<
what ();
118 return (sstream.str ());
142 const std::string& file_name =
"",
143 const std::string& function_name =
"" ,
144 unsigned line_number = 0) throw ()
145 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
156 const std::string& file_name =
"",
157 const std::string& function_name =
"" ,
158 unsigned line_number = 0) throw ()
159 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
171 const std::string& file_name =
"",
172 const std::string& function_name =
"" ,
173 unsigned line_number = 0) throw ()
174 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
185 const std::string& file_name =
"",
186 const std::string& function_name =
"" ,
187 unsigned line_number = 0) throw ()
188 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
199 const std::string& file_name =
"",
200 const std::string& function_name =
"" ,
201 unsigned line_number = 0) throw ()
202 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
214 const std::string& file_name =
"",
215 const std::string& function_name =
"" ,
216 unsigned line_number = 0) throw ()
217 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
228 const std::string& file_name =
"",
229 const std::string& function_name =
"" ,
230 unsigned line_number = 0) throw ()
231 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
238 const std::string& file_name =
"",
239 const std::string& function_name =
"" ,
240 unsigned line_number = 0) throw ()
241 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
248 const std::string& file_name =
"",
249 const std::string& function_name =
"" ,
250 unsigned line_number = 0) throw ()
251 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
261 const std::string& file_name =
"",
262 const std::string& function_name =
"" ,
263 unsigned line_number = 0) throw ()
264 :
pcl::
PCLException (error_description, file_name, function_name, line_number) { }
An exception that is thrown when a sample consensus model doesn't have the correct number of samples ...
const std::string & getFunctionName() const
KernelWidthTooSmallException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
An exception that is thrown when a PointCloud is not dense but is attemped to be used as dense...
A base class for all pcl exceptions which inherits from std::runtime_error.
UnorganizedPointCloudException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
An exception that is thrown when the argments number or type is wrong/unhandled.
InvalidSACModelTypeException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
An exception that is thrown when the kernel size is too small.
const std::string & getFileName() const
char const * what() const
An exception thrown when init can not be performed should be used in all the PCLBase class inheritant...
UnhandledPointTypeException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
ComputeFailedException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
An exception that is thrown during an IO error (typical read/write errors)
InvalidConversionException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
PCLException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
An exception that is thrown when an organized point cloud is needed but not provided.
An exception that is thrown when a PCLPointCloud2 message cannot be converted into a PCL type...
unsigned getLineNumber() const
IsNotDenseException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
IOException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
InitFailedException(const std::string &error_description="", const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
std::string detailedMessage() const
BadArgumentException(const std::string &error_description, const std::string &file_name="", const std::string &function_name="", unsigned line_number=0)
std::string function_name_