RollingFileLogHandler
classin packageklyn.logging.handler
public final class RollingFileLogHandler extends FileLogHandler:
└ RollingFileLogHandler

Rotates a text log file when it reaches a configured size.

Existing files are renamed to .1, .2, and so on, with the oldest file removed when the retention count is exceeded.

Example
import klyn.logging.handler

handler = RollingFileLogHandler("application.log", 10_000_000l, 5)
Inherited Properties
propertyInherited Properties from AbstractLogHandler: minimumLevel
Constructors
Modifier and Type Member Description
public RollingFileLogHandler
RollingFileLogHandler( path as String, maximumBytes as Long, files as Int = 10, minimumLevel as LogLevel = LogLevel.TRACE ):
Creates a rolling handler.
Inherited Methods
methodInherited Methods from FileLogHandler: close, flush, handle
methodInherited Methods from AbstractLogHandler: accepts, close, flush, handle
methodInherited Methods from AutoClosable: close
methodInherited Methods from LogHandler: accepts, flush, handle