Builder<DefaultRolloverStrategy>
public static class DefaultRolloverStrategy.Builder extends Object implements Builder<DefaultRolloverStrategy>
Constructor | Description |
---|---|
Builder() |
public DefaultRolloverStrategy build()
Builder
build
in interface Builder<DefaultRolloverStrategy>
public String getMax()
public DefaultRolloverStrategy.Builder withMax(String max)
max
- The maximum number of files to keep.public String getMin()
public DefaultRolloverStrategy.Builder withMin(String min)
min
- The minimum number of files to keep.public String getFileIndex()
public DefaultRolloverStrategy.Builder withFileIndex(String fileIndex)
fileIndex
- If set to "max" (the default), files with a higher index will be newer than files with a smaller
index. If set to "min", file renaming and the counter will follow the Fixed Window strategy.public String getCompressionLevelStr()
public DefaultRolloverStrategy.Builder withCompressionLevelStr(String compressionLevelStr)
compressionLevelStr
- The compression level, 0 (less) through 9 (more); applies only to ZIP files.public Action[] getCustomActions()
public DefaultRolloverStrategy.Builder withCustomActions(Action[] customActions)
customActions
- custom actions to perform asynchronously after rolloverpublic boolean isStopCustomActionsOnError()
public DefaultRolloverStrategy.Builder withStopCustomActionsOnError(boolean stopCustomActionsOnError)
stopCustomActionsOnError
- whether to stop executing asynchronous actions if an error occurspublic String getTempCompressedFilePattern()
public DefaultRolloverStrategy.Builder withTempCompressedFilePattern(String tempCompressedFilePattern)
tempCompressedFilePattern
- File pattern of the working file pattern used during compression, if null no temporary file are usedpublic Configuration getConfig()
public DefaultRolloverStrategy.Builder withConfig(Configuration config)
config
- The Configuration.Copyright © 1999-2018. All Rights Reserved.
Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.