Package org.exolab.castor.persist
Enum FieldPersistenceType
- java.lang.Object
-
- java.lang.Enum<FieldPersistenceType>
-
- org.exolab.castor.persist.FieldPersistenceType
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Comparable<FieldPersistenceType>
public enum FieldPersistenceType extends java.lang.Enum<FieldPersistenceType>
Enumeration for field type in the context of persistence; it is distinguished between primitive fields, serializable fields and relational fields (one-to-one, one-to-many and many-to-many).- Since:
- 1.3.2
- Author:
- me
-
-
Enum Constant Summary
Enum Constants Enum Constant Description MANY_TO_MANY
ONE_TO_MANY
PERSISTANCECAPABLE
PRIMITIVE
SERIALIZABLE
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static FieldPersistenceType
fromValue(int value)
Method fromValue().static FieldPersistenceType
fromValue(short value)
Method fromValue.short
value()
Method value.static FieldPersistenceType
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static FieldPersistenceType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
PRIMITIVE
public static final FieldPersistenceType PRIMITIVE
-
SERIALIZABLE
public static final FieldPersistenceType SERIALIZABLE
-
PERSISTANCECAPABLE
public static final FieldPersistenceType PERSISTANCECAPABLE
-
ONE_TO_MANY
public static final FieldPersistenceType ONE_TO_MANY
-
MANY_TO_MANY
public static final FieldPersistenceType MANY_TO_MANY
-
-
Method Detail
-
values
public static FieldPersistenceType[] 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 (FieldPersistenceType c : FieldPersistenceType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static FieldPersistenceType 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
-
fromValue
public static FieldPersistenceType fromValue(int value)
Method fromValue().- Parameters:
value
- The actual value as int.- Returns:
- the constant for this value.
-
fromValue
public static FieldPersistenceType fromValue(short value)
Method fromValue.- Parameters:
The
- actual value.- Returns:
- the constant for this value.
-
value
public short value()
Method value.- Returns:
- the value of this constant.
-
-