Class IntegerEnumField<E extends io.datarouter.util.enums.IntegerEnum<E>>
java.lang.Object
io.datarouter.model.field.BaseField<E>
io.datarouter.model.field.imp.enums.IntegerEnumField<E>
- All Implemented Interfaces:
ByteEncodedField<E>,StringEncodedField<E>,Field<E>,Comparable<Field<E>>
public class IntegerEnumField<E extends io.datarouter.util.enums.IntegerEnum<E>> extends BaseField<E>
-
Nested Class Summary
Nested classes/interfaces inherited from class io.datarouter.model.field.BaseField
BaseField.FieldColumnNameComparator -
Field Summary
-
Constructor Summary
Constructors Constructor Description IntegerEnumField(IntegerEnumFieldKey<E> key, E value) -
Method Summary
Modifier and Type Method Description intcompareTo(Field<E> other)EfromBytesButDoNotSet(byte[] bytes, int offset)byte[]getBytes()IntegerEnumFieldKey<E>getKey()EgetSampleValue()StringgetStringEncodedValue()StringgetValueString()intnumBytesWithSeparator(byte[] bytes, int offset)EparseStringEncodedValueButDoNotSet(String str)Methods inherited from class io.datarouter.model.field.BaseField
fromBytesWithSeparatorButDoNotSet, fromString, getBytesWithSeparator, getPrefix, getPrefixedName, getPreparedStatementValue, getValue, getValueHashCode, setPrefix, setUsingReflection, setValue, toString
-
Constructor Details
-
Method Details
-
getKey
-
getSampleValue
-
compareTo
-
getStringEncodedValue
-
parseStringEncodedValueButDoNotSet
-
getBytes
public byte[] getBytes() -
numBytesWithSeparator
public int numBytesWithSeparator(byte[] bytes, int offset) -
fromBytesButDoNotSet
-
getValueString
- Specified by:
getValueStringin interfaceField<E extends io.datarouter.util.enums.IntegerEnum<E>>- Overrides:
getValueStringin classBaseField<E extends io.datarouter.util.enums.IntegerEnum<E>>- Returns:
- a human-readable string for use in toString() methods. Should not be used for persistence.
-