49 static std::string
get() {
50 return std::string( T::classinfo->className );
57 #define DECLARE_CUSTOM_TTYPENAME(_TYPE) \
58 namespace mrpt { namespace utils { MRPT_DECLARE_TTYPENAME(_TYPE) } }
60 #define MRPT_DECLARE_TTYPENAME(_TYPE) \
61 template<> struct TTypeName <_TYPE > { \
62 static std::string get() { return std::string(#_TYPE); } };
64 #define MRPT_DECLARE_TTYPENAME_NAMESPACE(_TYPE,__NS) \
65 template<> struct TTypeName <__NS :: _TYPE > { \
66 static std::string get() { return std::string(#_TYPE); } };
68 #define MRPT_DECLARE_TTYPENAME_PTR(_TYPE) \
69 template<> struct TTypeName <_TYPE##Ptr> { \
70 static std::string get() { return TTypeName<_TYPE>::get(); } };
72 #define MRPT_DECLARE_TTYPENAME_PTR_NAMESPACE(_TYPE,__NS) \
73 template<> struct TTypeName <__NS :: _TYPE##Ptr> { \
74 static std::string get() { return TTypeName<__NS :: _TYPE>::get(); } };
#define MRPT_DECLARE_TTYPENAME(_TYPE)
This is the global namespace for all Mobile Robot Programming Toolkit (MRPT) libraries.
A template to obtain the type of its argument as a string at compile time.