Package org.apache.openjpa.persistence
Interface OpenJPAEnum<E extends java.lang.Enum<?>>
-
- Type Parameters:
E- the enum type that needs to be converted.
- All Known Implementing Classes:
FetchMode,IsolationLevel,LRSSizeAlgorithm,ResultSetType
public interface OpenJPAEnum<E extends java.lang.Enum<?>>An interface to define conversion of a facade based enum to a kernel integer constant. Facade specific enums implement this interface to convert user specified string or integer.- Since:
- 2.0.0
- Author:
- Pinaki Poddar
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intconvertToKernelConstant(int i)Convert the given integer to an equivalent kernel constant.intconvertToKernelConstant(java.lang.String s)Convert the given String to an equivalent kernel constant.inttoKernelConstant()Convert this receiver to an equivalent kernel constant.
-
-
-
Method Detail
-
toKernelConstant
int toKernelConstant()
Convert this receiver to an equivalent kernel constant.
-
convertToKernelConstant
int convertToKernelConstant(int i)
Convert the given integer to an equivalent kernel constant. This method has a static semantics in the sense that it can be invoked on any enum instance, but the conversion is done w.r.t. all enums of the generic type.
-
convertToKernelConstant
int convertToKernelConstant(java.lang.String s)
Convert the given String to an equivalent kernel constant. This method has a static semantics in the sense that it can be invoked on any enum instance, but the conversion is done w.r.t. all enums of the generic type.
-
-