Logging diagnostic messages

All applications and services in the Mongoose framework use a common message logging facility. This enables the framework to provide a single, consolidated view of all activity logged on the local machine. For developers, this log is available in the IDO Runtime Development Server (IDORuntimeHost.exe).

Message Logging API

public static void LogUserMessage( 
   string messageSource, 
   UserDefinedMessageType messageType, 
   string message) 
{ 
} 

public static void LogUserMessage( 
   string messageSource, 
   UserDefinedMessageType messageType, 
   string format, params object[] args) 
{ 
} 

Parameters

  • messageSource: A short, user-defined identifier of the source of a message (for example, class or project name)
  • messageType: One of the UserDefinedMessageType enumeration values; used for searching and filtering log messages
  • message: A string containing the log message text
  • format: A log message format string (see “String.Format()” in the .NET Framework documentation for more information about formatting strings)
  • args: A variable-length list of format-string substitution parameters

Examples

IDORuntime.LogUserMessage(
   "SLCustomers",
   UserDefinedMessageType.UserDefined0,
   "Method A() called.");

IDORuntime.LogUserMessage( 
   "SLCustomers", 
   UserDefinedMessageType.UserDefined0,
   "Parameter 1 is {0}.",
   p1);