org.vraptor.converter
Class SimpleConverterManager

java.lang.Object
  extended by org.vraptor.converter.SimpleConverterManager
All Implemented Interfaces:
ConverterManager

public class SimpleConverterManager
extends Object
implements ConverterManager

Converter repository.

Author:
Guilherme Silveira

Constructor Summary
SimpleConverterManager()
           
 
Method Summary
 Object convert(String[] arrayValue, String completeValue, Class<?> originalType, LogicRequest context, Class<? extends Converter> overridenConverter)
          Performs convertion
 void register(Converter converter)
          Registers a new converter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleConverterManager

public SimpleConverterManager()
Method Detail

register

public void register(Converter converter)
Registers a new converter

Specified by:
register in interface ConverterManager
Parameters:
converter - the converter itself

convert

public Object convert(String[] arrayValue,
                      String completeValue,
                      Class<?> originalType,
                      LogicRequest context,
                      Class<? extends Converter> overridenConverter)
               throws ConversionException
Description copied from interface: ConverterManager
Performs convertion

Specified by:
convert in interface ConverterManager
Parameters:
arrayValue - array value
completeValue - complete value in a string
originalType - original type
context - context
Returns:
the converted value
Throws:
ConversionException - some problem has occured


Copyright © 2004-2008 VRaptor. All Rights Reserved.