wx.Log Class Reference

Inheritance diagram for wx.Log:

wx.Object

List of all members.

Public Types

enum  eLogLevel

Public Member Functions

 Log ()
 Log (IntPtr wxObject)

Static Public Member Functions

static void AddTraceMask (wxString tmask)
static void AddTraceMask (string tmask)
static void ClearTraceMask ()
static void FlushActive ()
static bool IsAllowedTraceMask (wxString tmask)
static bool IsAllowedTraceMask (string tmask)
static void LogError (wxString message)
static void LogError (string message)
static void LogError (string message, params object[] param)
static void LogFatalError (wxString message)
static void LogFatalError (string message)
static void LogFatalError (string message, params object[] param)
static void LogInfo (wxString message)
static void LogInfo (string message)
static void LogInfo (string message, params object[] param)
static void LogMessage (wxString message)
static void LogMessage (string message)
static void LogMessage (string message, params object[] param)
static void LogStatus (wxString message)
static void LogStatus (string message)
static void LogStatus (string message, params object[] param)
static void LogSysError (wxString message)
static void LogSysError (string message)
static void LogSysError (string message, params object[] param)
static void LogTrace (wxString mask, wxString msg)
static void LogTrace (string mask, string format, params object[] param)
static void LogVerbose (wxString message)
static void LogVerbose (string message)
static void LogVerbose (string message, params object[] param)
static void LogWarning (wxString message)
static void LogWarning (string message)
static void LogWarning (string message, params object[] param)
static void RemoveTraceMask (wxString tmask)
static void RemoveTraceMask (string tmask)
static void Resume ()
static void SetActiveTarget (TextCtrl pLogger)
static void Suspend ()

Properties

static bool IsEnabled [get, set]
static string Timestamp [get, set]
static string[] TraceMasks [get]


Detailed Description

Wrapper of the wxWidgets log class. Refer to LogTraceListener for System.Diagnostics.Trace support.

Member Enumeration Documentation

enum wx::Log::eLogLevel

Enumerator:
xLOGMESSAGE 
xFATALERROR 
xERROR 
xWARNING 
xINFO 
xVERBOSE 
xSTATUS 
xSYSERROR 


Constructor & Destructor Documentation

wx.Log.Log ( IntPtr  wxObject  ) 

wx.Log.Log (  ) 


Member Function Documentation

static void wx.Log.AddTraceMask ( wxString  tmask  )  [static]

static void wx.Log.AddTraceMask ( string  tmask  )  [static]

Add the mask to the list of allowed masks for LogTrace().

static void wx.Log.ClearTraceMask (  )  [static]

static void wx.Log.FlushActive (  )  [static]

static bool wx.Log.IsAllowedTraceMask ( wxString  tmask  )  [static]

static bool wx.Log.IsAllowedTraceMask ( string  tmask  )  [static]

True if mask tmask is in TraceMasks(). This means that output with this mask will be logged.

static void wx.Log.LogError ( wxString  message  )  [static]

static void wx.Log.LogError ( string  message  )  [static]

static void wx.Log.LogError ( string  message,
params object[]  param 
) [static]

static void wx.Log.LogFatalError ( wxString  message  )  [static]

static void wx.Log.LogFatalError ( string  message  )  [static]

static void wx.Log.LogFatalError ( string  message,
params object[]  param 
) [static]

static void wx.Log.LogInfo ( wxString  message  )  [static]

static void wx.Log.LogInfo ( string  message  )  [static]

static void wx.Log.LogInfo ( string  message,
params object[]  param 
) [static]

static void wx.Log.LogMessage ( wxString  message  )  [static]

static void wx.Log.LogMessage ( string  message  )  [static]

static void wx.Log.LogMessage ( string  message,
params object[]  param 
) [static]

static void wx.Log.LogStatus ( wxString  message  )  [static]

static void wx.Log.LogStatus ( string  message  )  [static]

static void wx.Log.LogStatus ( string  message,
params object[]  param 
) [static]

static void wx.Log.LogSysError ( wxString  message  )  [static]

static void wx.Log.LogSysError ( string  message  )  [static]

static void wx.Log.LogSysError ( string  message,
params object[]  param 
) [static]

static void wx.Log.LogTrace ( wxString  mask,
wxString  msg 
) [static]

static void wx.Log.LogTrace ( string  mask,
string  format,
params object[]  param 
) [static]

Trace functions only do something in debug build and expand to nothing in the release one. The reason for making it a separate function from it is that usually there are a lot of trace messages, so it might make sense to separate them from other debug messages.

For the second function (taking a string mask), the message is logged only if the mask has been previously enabled by the call to AddTraceMask or by setting WXTRACE environment variable. The predefined string trace masks used by wxWidgets are:

static void wx.Log.LogVerbose ( wxString  message  )  [static]

static void wx.Log.LogVerbose ( string  message  )  [static]

static void wx.Log.LogVerbose ( string  message,
params object[]  param 
) [static]

static void wx.Log.LogWarning ( wxString  message  )  [static]

static void wx.Log.LogWarning ( string  message  )  [static]

static void wx.Log.LogWarning ( string  message,
params object[]  param 
) [static]

static void wx.Log.RemoveTraceMask ( wxString  tmask  )  [static]

static void wx.Log.RemoveTraceMask ( string  tmask  )  [static]

Remove the mask from the list of allowed masks for LogTrace(). See also: AddTraceMask().

static void wx.Log.Resume (  )  [static]

static void wx.Log.SetActiveTarget ( TextCtrl  pLogger  )  [static]

at the moment only TextCtrl

static void wx.Log.Suspend (  )  [static]


Property Documentation

bool wx.Log.IsEnabled [static, get, set]

Read whether this is enabled or not and enable or disable assigning true or false respectively. By the way - this will manage two flags for enable /diable: On in the native wxWidgets implementations and one in the managed code. Goal: If logging is disabled, wx.NET will not even call the native DLL functions.

string wx.Log.Timestamp [static, get, set]

Gets or sets the timestamp format prepended by the default log targets to all messages. The string may contain any normal characters as well as % prefixed format specificators, see strftime() manual for details. Passing a null value (not empty string) to this function disables message timestamping.

string [] wx.Log.TraceMasks [static, get]


Manual of the wx.NET   (c) 2003-2011 the wx.NET project at   Get wx.NET at SourceForge.net. Fast, secure and Free Open Source software downloads