ch.qos.logback.core.rolling
Class FixedWindowRollingPolicy

java.lang.Object
  extended by ch.qos.logback.core.spi.ContextAwareBase
      extended by ch.qos.logback.core.rolling.RollingPolicyBase
          extended by ch.qos.logback.core.rolling.FixedWindowRollingPolicy
All Implemented Interfaces:
RollingPolicy, ContextAware, LifeCycle

public class FixedWindowRollingPolicy
extends RollingPolicyBase

When rolling over, FixedWindowRollingPolicy renames files according to a fixed window algorithm. For more information about this policy, please refer to the online manual at http://logback.qos.ch/manual/appenders.html#FixedWindowRollingPolicy

Author:
Ceki Gülcü

Field Summary
static String ZIP_ENTRY_DATE_PATTERN
           
 
Fields inherited from class ch.qos.logback.core.rolling.RollingPolicyBase
compressionMode, fileNamePattern, fileNamePatternStr
 
Fields inherited from class ch.qos.logback.core.spi.ContextAwareBase
context
 
Constructor Summary
FixedWindowRollingPolicy()
           
 
Method Summary
 String getActiveFileName()
          Return the value of the parent's RawFile property.
 int getMaxIndex()
           
 int getMinIndex()
           
 void rollover()
          Rolls over log files according to implementation policy.
 void setMaxIndex(int maxIndex)
           
 void setMinIndex(int minIndex)
           
 void start()
           
 
Methods inherited from class ch.qos.logback.core.rolling.RollingPolicyBase
determineCompressionMode, getCompressionMode, getFileNamePattern, getParentsRawFileProperty, isParentPrudent, isStarted, setFileNamePattern, setParent, stop
 
Methods inherited from class ch.qos.logback.core.spi.ContextAwareBase
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getDeclaredOrigin, getStatusManager, setContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ZIP_ENTRY_DATE_PATTERN

public static final String ZIP_ENTRY_DATE_PATTERN
See Also:
Constant Field Values
Constructor Detail

FixedWindowRollingPolicy

public FixedWindowRollingPolicy()
Method Detail

start

public void start()
Specified by:
start in interface LifeCycle
Overrides:
start in class RollingPolicyBase

rollover

public void rollover()
              throws RolloverFailure
Description copied from interface: RollingPolicy
Rolls over log files according to implementation policy.

This method is invoked by RollingFileAppender, usually at the behest of its TriggeringPolicy.

Throws:
RolloverFailure - Thrown if the rollover operation fails for any reason.

getActiveFileName

public String getActiveFileName()
Return the value of the parent's RawFile property.


getMaxIndex

public int getMaxIndex()

getMinIndex

public int getMinIndex()

setMaxIndex

public void setMaxIndex(int maxIndex)

setMinIndex

public void setMinIndex(int minIndex)


Copyright © 2005-2013 QOS.ch. All Rights Reserved.