org.apache.log.output.io.rotate
Interface RotateStrategy

All Known Implementing Classes:
RotateStrategyBySize, OrRotateStrategy, RotateStrategyByTime

public interface RotateStrategy

Strategy that checks condition under which file rotation is needed.

Author:
Bernhard Huber

Method Summary
 boolean isRotationNeeded(java.lang.String data, java.io.File file)
          Check if a log rotation is neccessary at this time.
 void reset()
          reset cumulative rotation history data.
 

Method Detail

reset

public void reset()
reset cumulative rotation history data. Called after rotation.

isRotationNeeded

public boolean isRotationNeeded(java.lang.String data,
                                java.io.File file)
Check if a log rotation is neccessary at this time.
Parameters:
data - the serialized version of last message written to the log system
event - the LogEvent that initiated last message
file - the File that we are writing to
Returns:
boolean return true if log rotation is neccessary, else false


"Copyright © 2001 Apache Jakarta Project. All Rights Reserved."