vr.system
Class VisualLog

java.lang.Object
  extended by rseslib.system.AbstractLog
      extended by vr.system.VisualLog

public class VisualLog
extends rseslib.system.AbstractLog

Manager of messages. It manages three message streams: for errors, for information and for debugging messages. Errors are directed to error field in place defined by variable panel and after that they are converted into exceptions. The other two are also directed into suitable textfield. They can be also directed to files

Version:
0.8 2 Mar 2005
Author:
Marcin Staszczyk

Field Summary
 LogPanel panel
           
 
Fields inherited from class rseslib.system.AbstractLog
lineSeparator, s_bWriteDebug, s_bWriteDisplay, s_debugWriter, s_displayWriter
 
Constructor Summary
VisualLog()
          Object constructor creating his own window in witch it will be displaying his messages.
VisualLog(LogPanel lpanel)
          Object constructor receiving panel from outside.
 
Method Summary
 void debug(java.lang.String message)
          Writes a message on screen in debug field if the corresponding flag is set on.
 void debugnl()
          Writes a new line on screen in debug field and to file if the corresponding flag is set on
 void display(java.lang.Object obj)
          Writes an information about a given object if the corresponding flag is set on.
 void displaynl(java.lang.Object obj)
          Writes an information about a given object and append the end of line if the corresponding flag is set on.
 void error(java.lang.String message)
          Writes message on screen in debug field.
 void setHeaderFile(java.lang.String f)
          Sets information about loaded header file.
 void setHeaderModified(boolean b)
          Sets if header was modified
 void setOpenDebugWindow(boolean open)
          Opens or closes window with debug messages of subordinate LogPanel
 void setOpenDisplayWindow(boolean open)
          Opens or closes window with Iformation messages of subordinate LogPanel
 void setOpenErrorWindow(boolean open)
          Opens or closes window with error messages of subordinate LogPanel
 void setTestFile(java.lang.String f)
          Sets information about loaded test file.
 void setTestModified(boolean b)
          Sets if test was modified
 void setTrainingFile(java.lang.String f)
          Sets information about loaded training file.
 void setTrainingModified(boolean b)
          Sets if training was modified
 
Methods inherited from class rseslib.system.AbstractLog
close, displayMapWithMultiLines, displayMapWithSingleLines, openDebugFile, openDisplayFile, setDebug, setDisplay, test
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

panel

public LogPanel panel
Constructor Detail

VisualLog

public VisualLog()
Object constructor creating his own window in witch it will be displaying his messages.


VisualLog

public VisualLog(LogPanel lpanel)
Object constructor receiving panel from outside.

Parameters:
lpanel - Panel in witch new object will be displaying his messages..
Method Detail

error

public void error(java.lang.String message)
Writes message on screen in debug field.

Overrides:
error in class rseslib.system.AbstractLog
Parameters:
message - Error message.

debug

public void debug(java.lang.String message)
Writes a message on screen in debug field if the corresponding flag is set on. If the correspondinf file is set message is also wiritten to the file.

Specified by:
debug in class rseslib.system.AbstractLog
Parameters:
message - Komunikat debagowy.

debugnl

public void debugnl()
Writes a new line on screen in debug field and to file if the corresponding flag is set on

Specified by:
debugnl in class rseslib.system.AbstractLog

display

public void display(java.lang.Object obj)
Writes an information about a given object if the corresponding flag is set on.

Specified by:
display in class rseslib.system.AbstractLog
Parameters:
obj - Information message.

displaynl

public void displaynl(java.lang.Object obj)
Writes an information about a given object and append the end of line if the corresponding flag is set on.

Specified by:
displaynl in class rseslib.system.AbstractLog
Parameters:
obj - Information message.

setOpenErrorWindow

public void setOpenErrorWindow(boolean open)
Opens or closes window with error messages of subordinate LogPanel

Parameters:
open - Flag seting if window have to be open or closed.

setOpenDebugWindow

public void setOpenDebugWindow(boolean open)
Opens or closes window with debug messages of subordinate LogPanel

Parameters:
open - Flag seting if window have to be open or closed.

setOpenDisplayWindow

public void setOpenDisplayWindow(boolean open)
Opens or closes window with Iformation messages of subordinate LogPanel

Parameters:
open - Flag seting if window have to be open or closed.

setHeaderFile

public void setHeaderFile(java.lang.String f)
Sets information about loaded header file. If f is null or f is zero length string then it will be taken as info that no file is loaded and suitable message will be written on screen.

Parameters:
f - Inforation about loaded file.

setTrainingFile

public void setTrainingFile(java.lang.String f)
Sets information about loaded training file. If f is null or f is zero length string then it will be taken as info that no file is loaded and suitable message will be written on screen.

Parameters:
f - Inforation about loaded file.

setTestFile

public void setTestFile(java.lang.String f)
Sets information about loaded test file. If f is null or f is zero length string then it will be taken as info that no file is loaded and suitable message will be written on screen.

Parameters:
f - Inforation about loaded file.

setHeaderModified

public void setHeaderModified(boolean b)
Sets if header was modified


setTrainingModified

public void setTrainingModified(boolean b)
Sets if training was modified


setTestModified

public void setTestModified(boolean b)
Sets if test was modified