org.milyn.javabean.decoders
Class CustomDecoder

java.lang.Object
  extended by org.milyn.javabean.decoders.CustomDecoder
All Implemented Interfaces:
Serializable, Configurable, DataDecoder

public class CustomDecoder
extends Object
implements DataDecoder, Configurable

Custom decoder.

Specify a delegate decoder class in the properties.

Author:
tom.fennelly@gmail.com
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.milyn.javabean.DataDecoder
DataDecoder.Factory
 
Field Summary
static String CLASS_PROPERTY_NAME
           
 
Constructor Summary
CustomDecoder()
           
 
Method Summary
 Object decode(String data)
          Decode the supplied String data into a new Object data instance.
 Properties getConfiguration()
          Get the component configuration.
 DataDecoder getDelegateDecoder()
           
 void setConfiguration(Properties config)
          Set the component configuration.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_PROPERTY_NAME

public static final String CLASS_PROPERTY_NAME
See Also:
Constant Field Values
Constructor Detail

CustomDecoder

public CustomDecoder()
Method Detail

setConfiguration

public void setConfiguration(Properties config)
                      throws SmooksConfigurationException
Description copied from interface: Configurable
Set the component configuration.

Specified by:
setConfiguration in interface Configurable
Parameters:
config - The component configuration properties.
Throws:
SmooksConfigurationException - Bad component configuration.

getConfiguration

public Properties getConfiguration()
Description copied from interface: Configurable
Get the component configuration.

Specified by:
getConfiguration in interface Configurable
Returns:
The component configuration properties.

decode

public Object decode(String data)
              throws DataDecodeException
Description copied from interface: DataDecoder
Decode the supplied String data into a new Object data instance.

Specified by:
decode in interface DataDecoder
Parameters:
data - Data to be decoded.
Returns:
Decoded data Object.
Throws:
DataDecodeException - Error decoding data.

getDelegateDecoder

public DataDecoder getDelegateDecoder()


Copyright © 2018. All rights reserved.