Class jif.log.DiskLog
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class jif.log.DiskLog

java.lang.Object
   |
   +----java.io.RandomAccessFile
           |
           +----jif.log.DiskLog

public class DiskLog
extends RandomAccessFile
A class that allows log entries to be written to a disk file.
See Also:
RandomAccessFile

Constructor Index

 o DiskLog(String)
Builds a DiskLog object and creates a log file with a default name.
 o DiskLog(String, String)
Builds a DiskLog object and creates a log file with the specified name.

Method Index

 o createLogFileName()
Creates a log file name.
 o log(char, String)
Writes an entry to the log file

Constructors

 o DiskLog
  public DiskLog(String appName) throws IOException
Builds a DiskLog object and creates a log file with a default name.
Parameters:
appName - The name of the application using this log
 o DiskLog
  public DiskLog(String logName,
                 String name) throws IOException
Builds a DiskLog object and creates a log file with the specified name.
Parameters:
logName - The name of the log file
name - The name of the application using this log

Methods

 o createLogFileName
  protected static String createLogFileName()
Creates a log file name. Default name is "syslog."
 o log
  public void log(char logLevel,
                  String logEntry) throws IOException
Writes an entry to the log file
Parameters:
logLevel - The severity of the log entry
logEntry - The log entry

All Packages  Class Hierarchy  This Package  Previous  Next  Index