@MinDoc(copyright="Copyright 2009 A. Weinert", author="Albrecht Weinert", version="V.50", lastModified="4.06.2021", usage="use instead of String or int values", purpose="values for the possible modes for handling an existing file") public enum OutMode extends Enum<OutMode>
App
Enum Constant and Description |
---|
APPEND
Append at the end of the existing file.
|
ASK
Ask what to to if file exists.
|
NO_ACTION
No action / no change of an existing file.
|
OVERWRITE
Overwrite an existing file.
|
UPDATE
Update, Overwrite an existing file if certain criteria are met.
|
Modifier and Type | Field and Description |
---|---|
String |
name
The name of this OutMode.
|
int |
val
A value for this OutMode.
|
Modifier and Type | Method and Description |
---|---|
static OutMode |
of(CharSequence chose,
OutMode def)
Get an OutMode by character sequence.
|
String |
toString()
As String (the name).
|
static OutMode |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static OutMode[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final OutMode ASK
public static final OutMode APPEND
public static final OutMode OVERWRITE
public static final OutMode UPDATE
public static final OutMode NO_ACTION
public final String name
public final int val
public static OutMode[] values()
for (OutMode c : OutMode.values()) System.out.println(c);
public static OutMode valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static OutMode of(CharSequence chose, OutMode def)
chose
ignoring case: