Orocos Real-Time Toolkit  2.9.0
Public Member Functions | Public Attributes | List of all members
RTT::Logger::In Struct Reference

Notify the Logger in which 'module' the message occured. More...

#include <rtt/Logger.hpp>

Public Member Functions

 In (const std::string &module)
 
 ~In ()
 

Public Attributes

std::string oldmod
 

Detailed Description

Notify the Logger in which 'module' the message occured.

This returns an object whose scope (i.e. {...} ) is indicative for the boundaries of the module. This is reset to the previous module name (default is 'Logger') after the in object is destroyed. Practical usage must thus have the form:

{
    Logger::In("Mymodule");
    Logger::log() << Logger::Warning << "My warning message"<<Logger::nl;
    Logger::log() << "A second message, still in MyModule"<<Logger::nl;
}
Logger::log() << Logger::Info << "A message in module 'Logger'..."<<Logger::endl;

Definition at line 159 of file Logger.hpp.

Constructor & Destructor Documentation

RTT::Logger::In::In ( const std::string &  module)

Definition at line 403 of file Logger.cpp.

References RTT::Logger::in(), and RTT::Logger::log().

Referenced by RTT::Logger::operator<<().

RTT::Logger::In::~In ( )

Definition at line 409 of file Logger.cpp.

References RTT::Logger::log(), oldmod, and RTT::Logger::out().

Referenced by RTT::Logger::operator<<().

Member Data Documentation

std::string RTT::Logger::In::oldmod

Definition at line 162 of file Logger.hpp.

Referenced by ~In().


The documentation for this struct was generated from the following files: