Package org.apache.drill.exec.util
Enum ActionOnFile
- All Implemented Interfaces:
Serializable
,Comparable<ActionOnFile>
Defines possible actions on the file and performs the necessary action
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionabstract void
Action which should be performed on the filestatic ActionOnFile
Returns the enum constant of this type with the specified name.static ActionOnFile[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
NONE
No action will be performed -
RENAME
Renames the file by adding current timestamp value with "yyyyMMdd_HHmmss" format before last dot of original file nameExample:
Original file name: "storage-plugins-override.conf"
New file name: "storage-plugins-override-20180703_033354.conf" -
REMOVE
Removes the file
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified nameNullPointerException
- if the argument is null
-
action
Action which should be performed on the file- Parameters:
url
- the file URL
-