Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.autonomy.utilities
Class LogFile

    java.lang.Object
      |
      +--com.autonomy.utilities.LogFile

public class LogFile
extends java.lang.Object

Class to create and maintain log files.

Constructor Summary
`LogFile(java.lang.String sFileName, long lnMaxKb)` Create a log file.

Method Summary
`boolean` | `getLogging()` Check to see whether the log file is logging or not
`void` | `log(java.lang.String s)` Write the string s to the log file.
`void` | `Log(java.lang.String s)` Write the string s to the log file
`void` | `logThrowable(java.lang.Throwable t)` Writes the throwable's stack trace to the log file
`void` | `setDateStamp(int nNewVal)` The date format value is a series of flags to determine how much date information is written before each entry in the log file: If bit 0 is set, each log entry will be preceeded by the date. If bit 1 is set, each log entry will be preceeded by the time of day upto the second.
`void` | `setLogging(boolean bLogging)` If this is set to true, the log file will behave as normal.

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### LogFile

    public LogFile(java.lang.String sFileName,
                   long lnMaxKb)

  Create a log file.

Parameters:
  `sFileName` - Full path to the log file
  `lnMaxKb` - Maximum size of file before it is backed up and a new one started

Method Detail

### setLogging

    public void setLogging(boolean bLogging)

  If this is set to true, the log file will behave as normal. If it is false, the log file will not log anything

### getLogging

    public boolean getLogging()

  Check to see whether the log file is logging or not

### Log

    public void Log(java.lang.String s)

  Write the string s to the log file

### setDateStamp

    public void setDateStamp(int nNewVal)

  The date format value is a series of flags to determine how much date information is written before each entry in the log file:
  If bit 0 is set, each log entry will be preceeded by the date.
  If bit 1 is set, each log entry will be preceeded by the time of day upto the second.
  If bit 2 is set, each log entry will be preceeded by milliseconds.

  Parameters:
    `nNewVal` - New value of loggin flag. Use values between 0 - 7.

### log

    public void log(java.lang.String s)

  Write the string s to the log file.

### logThrowable

    public void logThrowable(java.lang.Throwable t)

  Writes the throwable's stack trace to the log file

  Parameters:
    `t` - Throwable (Exception or Error) to be logged

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD