Package org.ldaptive.transcode
Class AbstractPrimitiveValueTranscoder<T>
java.lang.Object
org.ldaptive.transcode.AbstractStringValueTranscoder<T>
org.ldaptive.transcode.AbstractPrimitiveValueTranscoder<T>
- Type Parameters:
T- type of object to transcode
- All Implemented Interfaces:
ValueTranscoder<T>
- Direct Known Subclasses:
BooleanValueTranscoder,DoubleValueTranscoder,FloatValueTranscoder,IntegerValueTranscoder,LongValueTranscoder,ShortValueTranscoder
Base class for primitive value transcoders.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate booleanWhether this transcoder operates on a primitive or an object. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionencodeStringValue(T value) Encodes the supplied value into an ldap attribute value.booleanReturns whether this transcoder operates on a primitive value.voidsetPrimitive(boolean b) Sets whether this transcoder operates on a primitive value.Methods inherited from class org.ldaptive.transcode.AbstractStringValueTranscoder
decodeBinaryValue, encodeBinaryValueMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.ldaptive.transcode.ValueTranscoder
decoder, decodeStringValue, encoder, getType
-
Field Details
-
primitive
private boolean primitiveWhether this transcoder operates on a primitive or an object.
-
-
Constructor Details
-
AbstractPrimitiveValueTranscoder
public AbstractPrimitiveValueTranscoder()
-
-
Method Details
-
isPrimitive
public boolean isPrimitive()Returns whether this transcoder operates on a primitive value.- Returns:
- whether this transcoder operates on a primitive value
-
setPrimitive
public void setPrimitive(boolean b) Sets whether this transcoder operates on a primitive value.- Parameters:
b- whether this transcoder operates on a primitive value
-
encodeStringValue
Description copied from interface:ValueTranscoderEncodes the supplied value into an ldap attribute value.- Parameters:
value- to encode- Returns:
- encoded value
-