SosTracer
| Kind of class: | class |
|---|---|
| Inherits from: | none |
| Implements: | |
| Version: | 1.0 |
| Author: | Francis Bourre, Pablo Costantini |
| Classpath: | com.bourre.utils.SosTracer |
| File last modified: | Wednesday, 31 October 2007, 07:35:30 |
SosTracer uses Powerflasher SOS consoleto log messages.
See http://sos.powerflasher.com/english.html for
more informations about SOS Console.
XMLSocket protocol is used for Pixlib /
SOS Console communication.
Implements com.bourre.log.LogListener interface to listen to
com.bourre.log.Logger events.
Example
Logger.getInstance().addLogListener( SosTracer.getInstance() );
PixlibDebug.INFO( "Logging API ready" );Summary
Class properties
Class methods
Instance methods
Event handlers
Class properties
DEBUG_FORMAT
static DEBUG_FORMAT:String = "DEBUG_FORMAT"
(read,write)
DEBUG_KEY
static DEBUG_KEY:String = '' + SosTracer.DEBUG_FORMAT + ' ' + 0x1394D6 + ' \n'
(read,write)
ERROR_FORMAT
static ERROR_FORMAT:String = "ERROR_FORMAT"
(read,write)
ERROR_KEY
static ERROR_KEY:String = '' + SosTracer.ERROR_FORMAT + ' ' + 0xFF6600 + ' \n'
(read,write)
FATAL_FORMAT
static FATAL_FORMAT:String = "FATAL_FORMAT"
(read,write)
FATAL_KEY
static FATAL_KEY:String = '' + SosTracer.FATAL_FORMAT + ' ' + 0xFF0000 + ' \n'
(read,write)
INFO_FORMAT
static INFO_FORMAT:String = "INFO_FORMAT"
(read,write)
INFO_KEY
static INFO_KEY:String = '' + SosTracer.INFO_FORMAT + ' ' + 0x12C9AC + ' \n'
(read,write)
IP
static IP:String = "localhost"
(read,write)
SOS console IP Address.
PORT
static PORT:Number = 4445
(read,write)
SOS console communication port.
WARN_FORMAT
static WARN_FORMAT:String = "WARN_FORMAT"
(read,write)
WARN_KEY
static WARN_KEY:String = '' + SosTracer.WARN_FORMAT + ' ' + 0xFFCC00 + ' \n'
(read,write)
Class methods
getInstance
static function getInstance (
) : SosTracer
Returns
SosTracer instance.Always return the same instance.
Returns:
SosTracer instanceInstance methods
clearOutput
function clearOutput (
) : Void
Clears SOS console.
getFoldMessage
function getFoldMessage (
sTitre:String,
sMessage:String,
level:LogLevel) : String
output
function output (
level:LogLevel) : Void
Sends message to SOS Console.
If communication with console is not ready,
messages are buffered.
Buffered messages are send to console when connection is
established.
toString
function toString (
) : String
Returns the string representation of this instance.
Returns:
the string representation of this instance
update
function update (
) : Void
Unity2 specific callbacksSends message to console
Parameters:
o :
infoObj:
Log info message
Event handlers
onLog
function onLog (
e:LogEvent) : Void
com.bourre.log.LogListener callback implementation.
com.bourre.log.Logger dispatches onLog
event when messages are send to logging API.
Parameters:
e:
A com.bourre.log.LogEvent instance.
Specified by: