Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.cantaloop.tools.conversion
Class TypedConverter  view TypedConverter download TypedConverter.java

java.lang.Object
  extended byorg.cantaloop.tools.conversion.TypedConverter

public class TypedConverter
extends java.lang.Object

A TypedConverter wraps a Converter. When you call the convert method of the TypedConverter, this call is delegated to the wrapped converter by using the class specified in the constructor as output type.

Version:
@version@ ($Revision: 1.4 $)

Field Summary
private  Converter m_conv
           
private  java.lang.Class m_type
           
 
Constructor Summary
TypedConverter(Converter c, java.lang.Class outputType)
           
 
Method Summary
 java.lang.Object convert(java.lang.Object obj)
           
 java.lang.Class getOutputType()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_conv

private Converter m_conv

m_type

private java.lang.Class m_type
Constructor Detail

TypedConverter

public TypedConverter(Converter c,
                      java.lang.Class outputType)
Method Detail

getOutputType

public java.lang.Class getOutputType()

convert

public java.lang.Object convert(java.lang.Object obj)
                         throws ConversionException