Examples of CalendarToXmlGregorianCalendarConverter


Examples of ma.glasnost.orika.converter.builtin.DateAndTimeConverters.CalendarToXmlGregorianCalendarConverter

  }
 
  @Test
  public void testCalendarToXmlGregorianCalendarConverter() {
    MapperFactory factory = MappingUtil.getMapperFactory();
    factory.getConverterFactory().registerConverter(new CalendarToXmlGregorianCalendarConverter());
    MapperFacade mapper = factory.getMapperFacade();
   
    Calendar cal = Calendar.getInstance();
    XMLGregorianCalendar xml = mapper.map(cal, XMLGregorianCalendar.class);
    Assert.assertEquals(cal.getTime(), xml.toGregorianCalendar().getTime());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.