public class LogFileViaCfgProps extends ErrorMessageMgr
Modifier and Type | Field and Description |
---|---|
CfgPropItem |
consoleFilesMaxAgeInDays
Console files maximum age in days (0=infinite).
|
CfgPropItem |
consoleFilesSwitchIntvlDays
Switch interval for console files, in days.
|
CfgPropItem |
consoleLevelProp
Message level for console output.
|
CfgPropItem |
consoleRedirectFileNameProp
Name of the console output redirect file.
|
protected java.io.PrintStream |
consoleRedirectStream
Output stream for redirected console output.
|
CfgPropItem |
logFileLevelProp
Message level for log file output.
|
CfgPropItem |
logFileNameProp
Name of the log file.
|
CfgProperties |
logFileProps
Configuration-properties object holding the log-file items.
|
CfgPropItem |
logFilesMaxAgeInDaysProp
Maximum age for log files (days, 0=infinite).
|
protected LogFile |
logObj
Log-file object.
|
Constructor and Description |
---|
LogFileViaCfgProps()
Creates an object for creating a log file using 'CfgPropItem'
objects.
|
LogFileViaCfgProps(CfgProperties cfgPropsObj)
Creates an object for creating a log file using 'CfgPropItem'
objects.
|
LogFileViaCfgProps(CfgProperties cfgPropsObj,
java.lang.Object groupSelObj)
Creates an object for creating a log file using 'CfgPropItem'
objects.
|
Modifier and Type | Method and Description |
---|---|
void |
addLogFilePropItems(CfgProperties cfgPropsObj)
Adds the log-file items to the given configuration-properties object.
|
void |
addLogFilePropItems(CfgProperties cfgPropsObj,
java.lang.Object groupSelObj)
Adds the log-file items to the given configuration-properties object.
|
void |
closeConsoleRedirectStream()
Closes the console-redirect object created via the 'createLogFile()'
method.
|
void |
closeLogFile()
Closes the log-file object created via the 'createLogFile()' method.
|
boolean |
createLogFile(boolean abortOnErrorFlag)
Creates a log file and sets it up using the configuration-property
item objects.
|
java.io.PrintStream |
getConsoleRedirectStreamObj()
Returns the console-redirect object created via the 'createLogFile()'
method.
|
LogFile |
getLogFileObj()
Returns the log-file object created via the 'createLogFile()' method.
|
void |
setGroupSelObj(java.lang.Object groupSelObj)
Sets the group-selection object for the log-file items.
|
clearErrorMessageString, clearFetchedErrorMessage, enterErrorMessageString, getErrorMessageFlag, getErrorMessageString, getUnfetchedMessageFlag, setErrorMessageString
protected LogFile logObj
protected java.io.PrintStream consoleRedirectStream
public final CfgProperties logFileProps
public final CfgPropItem consoleRedirectFileNameProp
public final CfgPropItem logFileNameProp
public final CfgPropItem logFileLevelProp
public final CfgPropItem consoleLevelProp
public final CfgPropItem logFilesMaxAgeInDaysProp
public final CfgPropItem consoleFilesSwitchIntvlDays
public final CfgPropItem consoleFilesMaxAgeInDays
public LogFileViaCfgProps()
public LogFileViaCfgProps(CfgProperties cfgPropsObj, java.lang.Object groupSelObj)
cfgPropsObj
- the configuration-properties object to use.groupSelObj
- the configuration-group-selection object to use,
or null for none.public LogFileViaCfgProps(CfgProperties cfgPropsObj)
cfgPropsObj
- the configuration-properties object to use.public final void addLogFilePropItems(CfgProperties cfgPropsObj, java.lang.Object groupSelObj)
cfgPropsObj
- the configuration-properties object to use.groupSelObj
- the configuration-group-selection object to use,
or null for none.public final void addLogFilePropItems(CfgProperties cfgPropsObj)
cfgPropsObj
- the configuration-properties object to use.public final void setGroupSelObj(java.lang.Object groupSelObj)
groupSelObj
- the configuration-group-selection object to use,
or null for none.public boolean createLogFile(boolean abortOnErrorFlag)
abortOnErrorFlag
- if true then this method will return
immediately after the first error is flagged (without creating
the log file); if false then this method will always create the
log file.public LogFile getLogFileObj()
public void closeLogFile()
public java.io.PrintStream getConsoleRedirectStreamObj()
public void closeConsoleRedirectStream()