Package org.apache.log.output.io.rotate
Class RotateStrategyByDate
- java.lang.Object
-
- org.apache.log.output.io.rotate.RotateStrategyByDate
-
- All Implemented Interfaces:
RotateStrategy
public class RotateStrategyByDate extends java.lang.Object implements RotateStrategy
Rotation stragety based on SimpleDateFormat.- Version:
- $Id: RotateStrategyByDate.java 30977 2004-07-30 03:57:54 -0500 (Fri, 30 Jul 2004) niclas $
-
-
Constructor Summary
Constructors Constructor Description RotateStrategyByDate()
Creation of a new rotation strategy based on a date policy.RotateStrategyByDate(java.lang.String pattern)
Creation of a new rotation strategy based on a date policy using a supplied pattern.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isRotationNeeded(java.lang.String data, java.io.File file)
Test is a rotation is required.void
reset()
Reset the strategy.
-
-
-
Constructor Detail
-
RotateStrategyByDate
public RotateStrategyByDate()
Creation of a new rotation strategy based on a date policy.
-
RotateStrategyByDate
public RotateStrategyByDate(java.lang.String pattern)
Creation of a new rotation strategy based on a date policy using a supplied pattern.- Parameters:
pattern
- the message formatting pattern
-
-
Method Detail
-
reset
public void reset()
Reset the strategy.- Specified by:
reset
in interfaceRotateStrategy
-
isRotationNeeded
public boolean isRotationNeeded(java.lang.String data, java.io.File file)
Test is a rotation is required. Documentation pending ??- Specified by:
isRotationNeeded
in interfaceRotateStrategy
- Parameters:
data
- not usedfile
- not used- Returns:
- TRUE if a rotation is required else FALSE
-
-