org.ldaptive.beans.reflect
Interface ReflectionTranscoder

All Known Implementing Classes:
AbstractCollectionReflectionTranscoder, ArrayReflectionTranscoder, DefaultReflectionTranscoder, ListReflectionTranscoder, SetReflectionTranscoder, SingleValueReflectionTranscoder

public interface ReflectionTranscoder

Interface for reflection based transcoders.

Version:
$Revision: 2887 $ $Date: 2014-02-26 12:23:53 -0500 (Wed, 26 Feb 2014) $
Author:
Middleware Services

Method Summary
 Object decodeBinaryValues(Collection<byte[]> values)
          Decodes the supplied values into an object.
 Object decodeStringValues(Collection<String> values)
          Decodes the supplied values into an object.
 Collection<byte[]> encodeBinaryValues(Object value)
          Encodes the supplied value into one or more byte arrays for use in an attribute.
 Collection<String> encodeStringValues(Object value)
          Encodes the supplied value into one or more strings for use in an attribute.
 Class<?> getType()
          Returns the type produced by this transcoder.
 boolean supports(Class<?> type)
          Returns whether this transcoder can convert object of the supplied type.
 

Method Detail

decodeStringValues

Object decodeStringValues(Collection<String> values)
Decodes the supplied values into an object.

Parameters:
values - to decode
Returns:
object initialized with the values

decodeBinaryValues

Object decodeBinaryValues(Collection<byte[]> values)
Decodes the supplied values into an object.

Parameters:
values - to decode
Returns:
object initialized with the values

encodeStringValues

Collection<String> encodeStringValues(Object value)
Encodes the supplied value into one or more strings for use in an attribute.

Parameters:
value - containing data to encode as strings
Returns:
string attribute values

encodeBinaryValues

Collection<byte[]> encodeBinaryValues(Object value)
Encodes the supplied value into one or more byte arrays for use in an attribute.

Parameters:
value - containing data to encode as byte arrays
Returns:
binary attribute values

getType

Class<?> getType()
Returns the type produced by this transcoder.

Returns:
type produced by this transcoder

supports

boolean supports(Class<?> type)
Returns whether this transcoder can convert object of the supplied type.

Parameters:
type - of object
Returns:
whether the supplied type can be converted


Copyright © 2003-2016 Virginia Tech. All Rights Reserved.