- All Implemented Interfaces:
Serializable
,Comparable<FilePolicy>
,Constable
File naming strategies for rotating files.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionDate based - "filename-yyyy-mm-dd", with nightly rollover.Use a fixed fileFiles are filename-0001, filename-0002, ..Always write to a file with the base filename.Timestamp with explicit roll over by callingManagedOutput.rotate()
The file format is "filename-yyyy-mm-dd_hh-mm-ss". -
Method Summary
Modifier and TypeMethodDescriptionstatic FilePolicy
static FilePolicy
Returns the enum constant of this class with the specified name.static FilePolicy[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Enum Constant Details
-
DATE
Date based - "filename-yyyy-mm-dd", with nightly rollover. -
TIMESTAMP
Timestamp with explicit roll over by callingManagedOutput.rotate()
The file format is "filename-yyyy-mm-dd_hh-mm-ss". -
INDEX
Files are filename-0001, filename-0002, .. and "rotate" means next index. -
SHIFT
Always write to a file with the base filename. On rotate, the files are shifted up as filename.001, filename.002, ... and the base filename used for a new file. -
FIXED
Use a fixed file
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
policy
-