Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037 #include <pcl/pcl_config.h>
00038 #ifdef HAVE_OPENNI
00039
00040 #include <pcl/io/openni_camera/openni_exception.h>
00041 #include <sstream>
00042
00043 namespace openni_wrapper
00044 {
00045
00046 OpenNIException::OpenNIException (const std::string& function_name, const std::string& file_name, unsigned line_number, const std::string& message) throw ()
00047 : function_name_ (function_name)
00048 , file_name_ (file_name)
00049 , line_number_ (line_number)
00050 , message_ (message)
00051 {
00052 std::stringstream sstream;
00053 sstream << function_name_ << " @ " << file_name_ << " @ " << line_number_ << " : " << message_;
00054 message_long_ = sstream.str();
00055 }
00056
00057 OpenNIException::~OpenNIException () throw ()
00058 {
00059 }
00060
00061 OpenNIException& OpenNIException::operator = (const OpenNIException& exception) throw ()
00062 {
00063 message_ = exception.message_;
00064 return *this;
00065 }
00066
00067 const char* OpenNIException::what () const throw ()
00068 {
00069 return message_long_.c_str();
00070 }
00071
00072 const std::string& OpenNIException::getFunctionName () const throw ()
00073 {
00074 return function_name_;
00075 }
00076
00077 const std::string& OpenNIException::getFileName () const throw ()
00078 {
00079 return file_name_;
00080 }
00081
00082 unsigned OpenNIException::getLineNumber () const throw ()
00083 {
00084 return line_number_;
00085 }
00086
00087 }
00088 #endif