Package org.apache.openjpa.persistence
Interface HintValueConverter
- All Known Implementing Classes:
HintValueConverter.EnumToInteger,HintValueConverter.OpenJPAEnumToInteger,HintValueConverter.StringToBoolean,HintValueConverter.StringToInteger,MixedLockLevelsHelper
public interface HintValueConverter
Converts a given user-specified value to a target type consumable by the kernel.
Used by hint processing.
- Since:
- 2.0.0
- Author:
- Pinaki Poddar
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classConvert the enum value to an enumerated set of constants.static classConverts an OpenJPA specific enum to an equivalent kernel constant.static classstatic classConverts a String to an integer. -
Method Summary
Modifier and TypeMethodDescriptionbooleancanConvert(Class<?> type) Affirm if this receiver can convert the value of the given type.Convert the user-specified value to a kernel consumable value.
-
Method Details
-
convert
Convert the user-specified value to a kernel consumable value.- Parameters:
original- the user-specified value- Returns:
- an equivalent value consumable by a kernel construct.
- Throws:
IllegalArgumentException- if the given value can not be converted.
-
canConvert
Affirm if this receiver can convert the value of the given type.
-