Package com.adobe.granite.ui.components
Enum FormData.NameNotFoundMode
- java.lang.Object
-
- java.lang.Enum<FormData.NameNotFoundMode>
-
- com.adobe.granite.ui.components.FormData.NameNotFoundMode
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<FormData.NameNotFoundMode>
- Enclosing class:
- FormData
public static enum FormData.NameNotFoundMode extends java.lang.Enum<FormData.NameNotFoundMode>
The mode on how to handle the scenario when the FormData doesn't have an entry of a certain name.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CHECK_FRESHNESS
When the FormData doesn't have an entry of a certain name, if the FormData is fresh then the value configured at the field is used instead, otherwise (it's not fresh) the value is taken from the FormData as usual, which will returnnull
.IGNORE_FRESHNESS
When the FormData doesn't have an entry of a certain name, then the value configured at the field is used instead.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static FormData.NameNotFoundMode
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static FormData.NameNotFoundMode[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
CHECK_FRESHNESS
public static final FormData.NameNotFoundMode CHECK_FRESHNESS
When the FormData doesn't have an entry of a certain name, if the FormData is fresh then the value configured at the field is used instead, otherwise (it's not fresh) the value is taken from the FormData as usual, which will returnnull
.The form is fresh when
jcr:created
property has equal value to the last modified property's value (taken from eitherjcr:lastModified
orcq:lastModified
). If either created or last modified date is not available, it is not considered as fresh.This mode is usually used for Authoring dialogs.
-
IGNORE_FRESHNESS
public static final FormData.NameNotFoundMode IGNORE_FRESHNESS
When the FormData doesn't have an entry of a certain name, then the value configured at the field is used instead.
-
-
Method Detail
-
values
public static FormData.NameNotFoundMode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (FormData.NameNotFoundMode c : FormData.NameNotFoundMode.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static FormData.NameNotFoundMode valueOf(java.lang.String name)
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:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
-