Package net.freedom.gj.beans.mapper

Examples of net.freedom.gj.beans.mapper.BeanMapper.map()


        // get an instance of bean mapper
        BeanMapper mapper = configureBeanMapper();

        // map object A to another object B
        EntityBeanB b2 = mapper.map(b1, new EntityBeanB());

        // Assert for correctness
        assertEquals(b1.getMyDate().toString(), (String)b2.getExtension().get("myDate") );
        assertEquals(b1.getName(), b2.getExtension().get("myName") );
        assertNotNull(b2.getEntityGroups());
View Full Code Here


        // get an instance of bean mapper
        BeanMapper mapper = configureBeanMapper();

        // map object A to another object B
        EntityBeanB b2 = mapper.map(b1, new EntityBeanB());

        // Assert for correctness
        assertEquals(b1.getMyDate().toString(), (String)b2.getExtension().get("myDate") );
        assertEquals(b1.getName(), b2.getExtension().get("myName") );
        assertNotNull(b2.getEntityGroups());
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.