#include <DebugHandler.h>
Public Member Functions | |
virtual void | DebugPrint (const char *) |
virtual bool | OutputToSocket (const char *text) |
virtual bool | EnableVisualDebuggerSocket (const int port=8000) |
virtual void | DisableVisualDebuggerSocket (void) |
virtual void | Printf (const char *format,...) |
virtual void | Poll (void) |
virtual bool | GotConnection (void) const |
virtual void | CallbackConnectionError (const int error) |
// Define the class class ApplicationDebugHandler : public RNReplicaNet::DebugHandler { public: ApplicationDebugHandler() {}; virtual ~ApplicationDebugHandler() {}; void DebugPrint(const char *text) { // TODO: Add applications specific code here // And optionally call the base class function RNReplicaNet::DebugHandler::DebugPrint(text); } }; #ifdef REPLICANET_VISUALDEBUGGER // In the application code, to enable the debug output RNReplicaNet::XPURL::RegisterDebugHandler(new ApplicationDebugHandler()); RNReplicaNet::XPURL::GetDebugHandler()->ConnectToVisualDebugger(); #endif
|
This virtual function is called when there is a connection error.
|
|
A virtual function that an application can implement to enable debug output. The default implementation calls OutputToSocket() |
|
This frees the socket used for the Visual Debugger connection. If connected to the Visual Debugger, this terminates the connection. If there is no socket allocated or connected this function does nothing. A PlatformHeap::ForceFree() will also disconnect any active Visual Debugger connection. |
|
This enables a TCP listen socket that can be used for connections from the Visual Debugger to this debug session. This function always calls DisableVisualDebuggerSocket() first.
|
|
Returns the state of the socket connection.
|
|
Outputs some text to the debug socket.
|
|
Called regularly by the library hosting the debug connection. Can also be called by the user. |
|
A variable argument printf style function that uses DebugPrint() to output the result
|