org.specrunner.converters.core
Class ConverterDefault

java.lang.Object
  extended by org.specrunner.converters.core.ConverterDefault
All Implemented Interfaces:
Serializable, IConverter, IResetable
Direct Known Subclasses:
ConverterString

public class ConverterDefault
extends Object
implements IConverter

Default converter. Bypass converter accepts everything.

Author:
Thiago Santos.
See Also:
Serialized Form

Constructor Summary
ConverterDefault()
           
 
Method Summary
 boolean accept(Object obj)
          Indicate if the converter accepts a given input value.
 Object convert(Object obj, Object[] args)
          Convert a given object to another using some arguments as auxiliary.
 void initialize()
          Initialize something.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConverterDefault

public ConverterDefault()
Method Detail

initialize

public void initialize()
Description copied from interface: IResetable
Initialize something.

Specified by:
initialize in interface IResetable

accept

public boolean accept(Object obj)
Description copied from interface: IConverter
Indicate if the converter accepts a given input value.

Specified by:
accept in interface IConverter
Parameters:
obj - The value.
Returns:
true, if accepted, false, otherwise.

convert

public Object convert(Object obj,
                      Object[] args)
               throws ConverterException
Description copied from interface: IConverter
Convert a given object to another using some arguments as auxiliary.

Specified by:
convert in interface IConverter
Parameters:
obj - The value to be converted.
args - The arguments.
Returns:
The converted object.
Throws:
ConverterException - On conversion errors.


Copyright © 2014. All rights reserved.