Package org.ldaptive.transcode
Class ObjectValueTranscoder
- java.lang.Object
-
- org.ldaptive.transcode.ObjectValueTranscoder
-
- All Implemented Interfaces:
ValueTranscoder<Object>
public class ObjectValueTranscoder extends Object implements ValueTranscoder<Object>
Decodes and encodes an object for use in an ldap attribute value.
-
-
Constructor Summary
Constructors Constructor Description ObjectValueTranscoder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ObjectdecodeBinaryValue(byte[] value)Decodes the supplied ldap attribute value into a custom type.ObjectdecodeStringValue(String value)Decodes the supplied ldap attribute value into a custom type.byte[]encodeBinaryValue(Object value)Encodes the supplied value into an ldap attribute value.StringencodeStringValue(Object value)Encodes the supplied value into an ldap attribute value.Class<Object>getType()Returns the type produced by this value transcoder.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.ldaptive.transcode.ValueTranscoder
decoder, encoder
-
-
-
-
Method Detail
-
decodeStringValue
public Object decodeStringValue(String value)
Description copied from interface:ValueTranscoderDecodes the supplied ldap attribute value into a custom type.- Specified by:
decodeStringValuein interfaceValueTranscoder<Object>- Parameters:
value- to decode- Returns:
- decoded value
-
decodeBinaryValue
public Object decodeBinaryValue(byte[] value)
Description copied from interface:ValueTranscoderDecodes the supplied ldap attribute value into a custom type.- Specified by:
decodeBinaryValuein interfaceValueTranscoder<Object>- Parameters:
value- to decode- Returns:
- decoded value
-
encodeStringValue
public String encodeStringValue(Object value)
Description copied from interface:ValueTranscoderEncodes the supplied value into an ldap attribute value.- Specified by:
encodeStringValuein interfaceValueTranscoder<Object>- Parameters:
value- to encode- Returns:
- encoded value
-
encodeBinaryValue
public byte[] encodeBinaryValue(Object value)
Description copied from interface:ValueTranscoderEncodes the supplied value into an ldap attribute value.- Specified by:
encodeBinaryValuein interfaceValueTranscoder<Object>- Parameters:
value- to encode- Returns:
- encoded value
-
getType
public Class<Object> getType()
Description copied from interface:ValueTranscoderReturns the type produced by this value transcoder.- Specified by:
getTypein interfaceValueTranscoder<Object>- Returns:
- type produced by this value transcoder
-
-