Package org.openflexo.pamela.annotations
Enum ModelEntity.InitPolicy
- java.lang.Object
-
- java.lang.Enum<ModelEntity.InitPolicy>
-
- org.openflexo.pamela.annotations.ModelEntity.InitPolicy
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<ModelEntity.InitPolicy>
- Enclosing class:
- ModelEntity
public static enum ModelEntity.InitPolicy extends java.lang.Enum<ModelEntity.InitPolicy>
Defines the different initialization policy of the model entity.- NONE: It is not mandatory to invoke any initializer although there are some declared on the entity
- WARN_IF_NOT_INVOKED: It is not mandatory to invoke any initializer although there are some declared on the entity, but a warning will be output if a new instance of the entity is used in the model
- REQUIRED: It is mandatory to invoke an initializer of the entity if there is at least on initializer defined in the entity
hierarchy. Using an instance of this entity without having initialized it will throw a ModelExcecutionException @see
ModelExecutionException
-
-
Enum Constant Summary
Enum Constants Enum Constant Description NONE
REQUIRED
WARN_IF_NOT_INVOKED
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ModelEntity.InitPolicy
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static ModelEntity.InitPolicy[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
NONE
public static final ModelEntity.InitPolicy NONE
-
WARN_IF_NOT_INVOKED
public static final ModelEntity.InitPolicy WARN_IF_NOT_INVOKED
-
REQUIRED
public static final ModelEntity.InitPolicy REQUIRED
-
-
Method Detail
-
values
public static ModelEntity.InitPolicy[] 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 (ModelEntity.InitPolicy c : ModelEntity.InitPolicy.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ModelEntity.InitPolicy 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
-
-