org.databene.benerator.parser
Class DefaultEntryConverter

java.lang.Object
  extended by org.databene.commons.converter.AbstractConverter<java.util.Map.Entry,java.util.Map.Entry>
      extended by org.databene.benerator.parser.DefaultEntryConverter
All Implemented Interfaces:
Converter<java.util.Map.Entry,java.util.Map.Entry>, ThreadAware

public class DefaultEntryConverter
extends AbstractConverter<java.util.Map.Entry,java.util.Map.Entry>

Converts Map entries by first applying a preprocessor to the value, then (if possible) converting the result to a number or boolean.

Created: 01.02.2008 14:40:43

Since:
0.4.0
Author:
Volker Bergmann

Field Summary
 
Fields inherited from class org.databene.commons.converter.AbstractConverter
sourceType, targetType
 
Constructor Summary
DefaultEntryConverter(BeneratorContext context)
           
DefaultEntryConverter(Converter<java.lang.String,java.lang.Object> preprocessor, BeneratorContext context, boolean putEntriesToContext)
           
 
Method Summary
 java.util.Map.Entry convert(java.util.Map.Entry entry)
          Concerts an object of type S to an object of type T
 boolean isParallelizable()
           
 boolean isThreadSafe()
           
 
Methods inherited from class org.databene.commons.converter.AbstractConverter
getSourceType, getTargetType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultEntryConverter

public DefaultEntryConverter(BeneratorContext context)

DefaultEntryConverter

public DefaultEntryConverter(Converter<java.lang.String,java.lang.Object> preprocessor,
                             BeneratorContext context,
                             boolean putEntriesToContext)
Method Detail

convert

public java.util.Map.Entry convert(java.util.Map.Entry entry)
                            throws ConversionException
Description copied from interface: Converter
Concerts an object of type S to an object of type T

Parameters:
entry - the object to convert
Returns:
the converted object
Throws:
ConversionException - if the conversion fails

isParallelizable

public boolean isParallelizable()

isThreadSafe

public boolean isThreadSafe()


Copyright © 2010. All Rights Reserved.