simulations.core.history
Class HistoryWriter

java.lang.Object
  extended by simulations.core.history.HistoryWriter

public class HistoryWriter
extends java.lang.Object

This class describes the writer of a history file


Constructor Summary
HistoryWriter(java.io.File file, int traceLevel)
          Creates a new instance of HistoryWriter
 
Method Summary
 void close()
          close the fileWriter
 java.io.File getFile()
          Getter for property file.
 int getTraceLevel()
          Getter for property traceLevel.
 void setFile(java.io.File file)
          Setter for property file.
 void setTraceLevel(int traceLevel)
          Setter for property traceLevel.
 void write(java.lang.String text)
          Write a string in the history file with the fileWriter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HistoryWriter

public HistoryWriter(java.io.File file,
                     int traceLevel)
              throws java.io.IOException
Creates a new instance of HistoryWriter

Parameters:
traceLevel - The trace level
file - The history file
Throws:
java.io.IOException - if an IO error occurs
Method Detail

write

public void write(java.lang.String text)
           throws java.io.IOException
Write a string in the history file with the fileWriter

Parameters:
text - The text to write
Throws:
java.io.IOException - if an IO error occurs

close

public void close()
           throws java.io.IOException
close the fileWriter

Throws:
java.io.IOException - if an IO error occurs

getFile

public java.io.File getFile()
Getter for property file.

Returns:
Value of property file.

setFile

public void setFile(java.io.File file)
Setter for property file.

Parameters:
file - New value of property file.

getTraceLevel

public int getTraceLevel()
Getter for property traceLevel.

Returns:
Value of property traceLevel.

setTraceLevel

public void setTraceLevel(int traceLevel)
Setter for property traceLevel.

Parameters:
traceLevel - New value of property traceLevel.