Package com.sun.javatest.util
Class LogFile
java.lang.Object
com.sun.javatest.util.LogFile
An object providing support for writing log messages to a file.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
log
(I18NResourceBundle i18n, String key) Print a text message to the logfile.void
log
(I18NResourceBundle i18n, String key, Object arg) Print a text message to the workdir logfile.void
log
(I18NResourceBundle i18n, String key, Object... args) Print a text message to the workdir logfile.
-
Constructor Details
-
LogFile
public LogFile()Create a log file object to which log messages can be written. The messages will be written to System.err. -
LogFile
Create a log file object to which log messages can be written.- Parameters:
out
- the stream to which to write the messages.
-
LogFile
Create a log file object to which log messages can be written.- Parameters:
file
- the file to which to write the messages.
-
-
Method Details
-
log
Print a text message to the logfile. A single line of text which is as short as possible is highly recommended for readability purposes.- Parameters:
i18n
- a resource bundle containing the localized messageskey
- a key into the resource bundle for the required message
-
log
Print a text message to the workdir logfile. A single line of text which is as short as possible is highly recommended for readability purposes.- Parameters:
i18n
- a resource bundle containing the localized messageskey
- a key into the resource bundle for the required messagearg
- An argument to be formatted into the specified message. If this is aThrowable
, its stack trace will be included in the log.
-
log
Print a text message to the workdir logfile. A single line of text which is as short as possible is highly recommended for readability purposes.- Parameters:
i18n
- a resource bundle containing the localized messageskey
- a key into the resource bundle for the required messageargs
- An array of arguments to be formatted into the specified message. If the first arg is aThrowable
, its stack trace will be included in the log.
-