Package org.apache.log4j.rolling
Class RolloverDescriptionImpl
- java.lang.Object
-
- org.apache.log4j.rolling.RolloverDescriptionImpl
-
- All Implemented Interfaces:
RolloverDescription
public final class RolloverDescriptionImpl extends java.lang.Object implements RolloverDescription
Description of actions needed to complete rollover.
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.StringactiveFileNameActive log file name after rollover.private booleanappendShould active file be opened for appending.private ActionasynchronousAction to be completed after close of current active log file and before next rollover attempt, may be executed asynchronously.private ActionsynchronousAction to be completed after close of current active log file before returning control to caller.
-
Constructor Summary
Constructors Constructor Description RolloverDescriptionImpl(java.lang.String activeFileName, boolean append, Action synchronous, Action asynchronous)Create new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetActiveFileName()Active log file name after rollover.booleangetAppend()Specifies if active file should be opened for appending.ActiongetAsynchronous()Action to be completed after close of current active log file and before next rollover attempt, may be executed asynchronously.ActiongetSynchronous()Action to be completed after close of current active log file before returning control to caller.
-
-
-
Field Detail
-
activeFileName
private final java.lang.String activeFileName
Active log file name after rollover.
-
append
private final boolean append
Should active file be opened for appending.
-
synchronous
private final Action synchronous
Action to be completed after close of current active log file before returning control to caller.
-
asynchronous
private final Action asynchronous
Action to be completed after close of current active log file and before next rollover attempt, may be executed asynchronously.
-
-
Constructor Detail
-
RolloverDescriptionImpl
public RolloverDescriptionImpl(java.lang.String activeFileName, boolean append, Action synchronous, Action asynchronous)Create new instance.- Parameters:
activeFileName- active log file name after rollover, may not be null.append- true if active log file after rollover should be opened for appending.synchronous- action to be completed after close of current active log file, may be null.asynchronous- action to be completed after close of current active log file and before next rollover attempt.
-
-
Method Detail
-
getActiveFileName
public java.lang.String getActiveFileName()
Active log file name after rollover.- Specified by:
getActiveFileNamein interfaceRolloverDescription- Returns:
- active log file name after rollover.
-
getAppend
public boolean getAppend()
Specifies if active file should be opened for appending.- Specified by:
getAppendin interfaceRolloverDescription- Returns:
- if true, active file should be opened for appending.
-
getSynchronous
public Action getSynchronous()
Action to be completed after close of current active log file before returning control to caller.- Specified by:
getSynchronousin interfaceRolloverDescription- Returns:
- action, may be null.
-
getAsynchronous
public Action getAsynchronous()
Action to be completed after close of current active log file and before next rollover attempt, may be executed asynchronously.- Specified by:
getAsynchronousin interfaceRolloverDescription- Returns:
- action, may be null.
-
-