public static enum ZapTextComponentUndoManager.UndoManagerPolicy extends Enum<ZapTextComponentUndoManager.UndoManagerPolicy>
UndoManagerPolicy.DEFAULT
UndoManagerPolicy.ALWAYS_ENABLED
UndoManagerPolicy.ALWAYS_DISABLED
DEFAULT
,
ALWAYS_ENABLED
,
ALWAYS_DISABLED
Enum Constant and Description |
---|
ALWAYS_DISABLED
The undoable edits are not saved.
|
ALWAYS_ENABLED
The undoable edits are always saved, even if the
JTextComponent is not editable
and/or enabled. |
DEFAULT
The undoable edits are saved exactly when the
JTextComponent is enabled and
editable. |
Modifier and Type | Method and Description |
---|---|
static ZapTextComponentUndoManager.UndoManagerPolicy |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ZapTextComponentUndoManager.UndoManagerPolicy[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ZapTextComponentUndoManager.UndoManagerPolicy DEFAULT
JTextComponent
is enabled and
editable.
The ZapTextComponentUndoManager
listens to the changes in the properties
"enabled" and "editable", so that can change accordingly to save or not the undoable
edits.
public static final ZapTextComponentUndoManager.UndoManagerPolicy ALWAYS_ENABLED
JTextComponent
is not editable
and/or enabled.public static final ZapTextComponentUndoManager.UndoManagerPolicy ALWAYS_DISABLED
public static ZapTextComponentUndoManager.UndoManagerPolicy[] values()
for (ZapTextComponentUndoManager.UndoManagerPolicy c : ZapTextComponentUndoManager.UndoManagerPolicy.values()) System.out.println(c);
public static ZapTextComponentUndoManager.UndoManagerPolicy 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 null