Package jodd.typeconverter.impl

Examples of jodd.typeconverter.impl.ClassConverter


    register(GregorianCalendar.class, new CalendarConverter());
    register(JDateTime.class, new JDateTimeConverter());

    register(File.class, new FileConverter());

    register(Class.class, new ClassConverter());
    register(Class[].class, new ClassArrayConverter(this));

    register(URI.class, new URIConverter());
    register(URL.class, new URLConverter());
View Full Code Here


public class ClassConverterTest {

  @Test
  public void testConversion() {
    ClassConverter classConverter = new ClassConverter();

    assertNull(classConverter.convert(null));

    assertEquals(String.class, classConverter.convert(String.class));
    assertEquals(Integer.class, classConverter.convert("java.lang.Integer"));

    try {
      classConverter.convert("foo.Klass");
      fail();
    } catch (TypeConversionException ignore) {
    }
  }
View Full Code Here

    register(GregorianCalendar.class, new CalendarConverter());
    register(JDateTime.class, new JDateTimeConverter());

    register(File.class, new FileConverter());

    register(Class.class, new ClassConverter());
    register(Class[].class, new ClassArrayConverter(this));

    register(URI.class, new URIConverter());
    register(URL.class, new URLConverter());
View Full Code Here

TOP

Related Classes of jodd.typeconverter.impl.ClassConverter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.