3 #ifndef ROBOWFLEX_LOGGING_
4 #define ROBOWFLEX_LOGGING_
6 #include <boost/format.hpp>
7 #include <ros/console.h>
47 template <
class T,
class... Args>
50 return formatRecurse(f % std::forward<T>(t), std::forward<Args>(args)...);
59 template <
typename... Args>
94 #define RBX_FATAL(fmt, ...) ROS_FATAL_STREAM(robowflex::log::format(fmt, ##__VA_ARGS__).c_str())
102 #define RBX_ERROR(fmt, ...) ROS_ERROR_STREAM(robowflex::log::format(fmt, ##__VA_ARGS__).c_str())
110 #define RBX_WARN(fmt, ...) ROS_WARN_STREAM(robowflex::log::format(fmt, ##__VA_ARGS__).c_str())
118 #define RBX_INFO(fmt, ...) ROS_INFO_STREAM(robowflex::log::format(fmt, ##__VA_ARGS__).c_str())
126 #define RBX_DEBUG(fmt, ...) ROS_DEBUG_STREAM(robowflex::log::format(fmt, ##__VA_ARGS__).c_str())
std::string format(const std::string &fmt, Args &&... args)
Recursion base case, return string form of formatted arguments.
void showUpToDebug()
Show all logging messages debug and above.
void showUpToWarning()
Show all logging messages warning and above.
void showUpToInfo()
Show all logging messages info and above.
void showUpToError()
Show all logging messages error and above.
void showUpToFatal()
Show all logging messages fatal and above.
std::string formatRecurse(boost::format &f)
Recursion base case, return string form of formatted arguments.
Main namespace. Contains all library classes and functions.