Package org.dozer.vo.iface

Examples of org.dozer.vo.iface.ApplicationUser


  @Test
  public void testInterface() throws Exception {
    log.info("Starting");
    mapper = getMapper("interfaceMapping.xml");
    { // warm up to load the config
      ApplicationUser source = new ApplicationUser();
      UpdateMember target = new UpdateMember();
      mapper.map(source, target);
    }
    for (int j = 1; j <= 16384; j += j) {
      long start = System.currentTimeMillis();
      for (int i = 0; i < j; i++) {
        ApplicationUser source = new ApplicationUser();
        UpdateMember target = new UpdateMember();
        mapper.map(source, target);
      }
      long applicationUserTime = (System.currentTimeMillis() - start);
      start = System.currentTimeMillis();
View Full Code Here


  }

  @Test
  public void testInterface() throws Exception {
    mapper = getMapper(new String[] { "interfaceMapping.xml" });
    ApplicationUser user = newInstance(ApplicationUser.class);
    user.setSubscriberNumber("123");

    // Mapping works
    UpdateMember destObject = mapper.map(user, UpdateMember.class);

    assertEquals("invalid value for subsriber #", user.getSubscriberNumber(), destObject.getSubscriberKey().getSubscriberNumber());

    // Clear value
    destObject = new UpdateMember();

    // Mapping doesn't work
    mapper.map(user, destObject);

    assertNotNull("dest field should not be null", destObject.getSubscriberKey());
    assertEquals("invalid value for subsriber #", user.getSubscriberNumber(), destObject.getSubscriberKey().getSubscriberNumber());
  }
View Full Code Here

  }

  @Test
  public void testInterface() throws Exception {
    mapper = getMapper("interfaceMapping.xml");
    ApplicationUser user = newInstance(ApplicationUser.class);
    user.setSubscriberNumber("123");

    // Mapping works
    UpdateMember destObject = mapper.map(user, UpdateMember.class);

    assertEquals("invalid value for subsriber #", user.getSubscriberNumber(), destObject.getSubscriberKey().getSubscriberNumber());

    // Clear value
    destObject = new UpdateMember();

    // Mapping doesn't work
    mapper.map(user, destObject);

    assertNotNull("dest field should not be null", destObject.getSubscriberKey());
    assertEquals("invalid value for subsriber #", user.getSubscriberNumber(), destObject.getSubscriberKey().getSubscriberNumber());
  }
View Full Code Here

  @Test
  public void testInterface() throws Exception {
    log.info("Starting");
    mapper = getMapper("interfaceMapping.xml");
    { // warm up to load the config
      ApplicationUser source = new ApplicationUser();
      UpdateMember target = new UpdateMember();
      mapper.map(source, target);
    }
    for (int j = 1; j <= 16384; j += j) {
      long start = System.currentTimeMillis();
      for (int i = 0; i < j; i++) {
        ApplicationUser source = new ApplicationUser();
        UpdateMember target = new UpdateMember();
        mapper.map(source, target);
      }
      long applicationUserTime = (System.currentTimeMillis() - start);
      start = System.currentTimeMillis();
View Full Code Here

TOP

Related Classes of org.dozer.vo.iface.ApplicationUser

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.