|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object courselog.DebugLogger
public class DebugLogger
Traces debugging in a TextArea and in System.out under Windows.
Field Summary | |
---|---|
protected ewe.io.FileWriter |
fLog
Output log file. |
boolean |
ISCONTROLENABLED
Configure the debug logger with a control. |
boolean |
ISFILEENABLED
Configure the debug logger with a file. |
protected boolean |
isFreezed
Freezed state. |
protected ewe.ui.Control |
logControl
scrolling control where items are displayed. |
java.lang.String |
LOGFILE
Dump file name. |
protected ewe.ui.mTextPad |
logPad
Textpad where items are displayed. |
protected java.lang.String |
stLogContent
logContent. |
Constructor Summary | |
---|---|
DebugLogger()
New instance of debuglogger. |
Method Summary | |
---|---|
void |
addExceptionToLog(java.lang.Exception exL)
Log an exception to the log file. |
void |
addToLog(java.lang.String msg)
Adds a string at the end of the log and displays the last line. |
protected int |
countLines(java.lang.String st)
Count the number of '\n' in a string to know the number of lines. |
void |
freezeLog()
Freeze log refreshing to reduce 'real-time' disturbance. |
ewe.ui.Control |
getLogControl()
Return the display control to any form that wants to display the logger. |
boolean |
isLogFreezed()
Test log refreshing state. |
void |
setLog(java.lang.String msg)
Set the log to the message, erasing previous content. |
void |
unFreezeLog()
Remove Freezed log refreshing to allow 'real-time' logging. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public final boolean ISCONTROLENABLED
public final boolean ISFILEENABLED
public final java.lang.String LOGFILE
protected ewe.ui.mTextPad logPad
protected ewe.ui.Control logControl
protected java.lang.String stLogContent
protected boolean isFreezed
protected ewe.io.FileWriter fLog
Constructor Detail |
---|
public DebugLogger()
Method Detail |
---|
public ewe.ui.Control getLogControl()
public void addExceptionToLog(java.lang.Exception exL)
ex
- Exception to log, with the stack trace.public void addToLog(java.lang.String msg)
msg
- Message to display. May contain '\n' characters.public void setLog(java.lang.String msg)
msg
- Message to display, may be multi-line using '\n' character.public void freezeLog()
public void unFreezeLog()
public boolean isLogFreezed()
protected int countLines(java.lang.String st)
st
- String where number of lines must be counted.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |