Using the Predefined Client
The Execution Tracing package provides one predefined client RWTraceOstreamClient. To instantiate the client, use code similar to this:
 
#include <rw/trace/trace.h>
. . .
RWTraceOstreamClient myTraceClient(cerr);
 
The RWTraceOstreamClient sends output to any ostream specified to its constructor, such as cerr in the above example. This code comes from Example 49.
After instantiation, connect the client to the trace manager using the client’s connectToManager() member function:
 
myTraceClient.connectToManager();
 
To connect the client to another filter, use the client’s connect() member function and pass it the filter as an argument:
 
RWTraceMultiClientFilter myMultiFilter;
myTraceClient.connect( myMultiFilter );
 
See Using Trace Filters for the discussion of filters.