Examples of toPojo()


Examples of org.nutz.dao.entity.Record.toPojo()

  }

  @Test
  public void fetch_record() {
    Record re = dao.fetch("t_pet", Cnd.where("name", "=", "pet3"));
    Pet pet = re.toPojo(Pet.class);
    assertEquals(5, re.getColumnCount());
    assertEquals(4, pet.getId());
    assertEquals("pet3", pet.getName());
  }
}
View Full Code Here

Examples of org.nutz.dao.entity.Record.toPojo()

    }

    @Test
    public void fetch_record() {
        Record re = dao.fetch("t_pet", Cnd.where("name", "=", "pet3"));
        Pet pet = re.toPojo(Pet.class);
        assertEquals(6, re.getColumnCount());
        assertEquals(4, pet.getId());
        assertEquals("pet3", pet.getName());
    }
View Full Code Here

Examples of org.nutz.dao.entity.Record.toPojo()

    @Test
    public void fetch_record() {
        Record re = dao.fetch("t_pet", Cnd.where("name", "=", "pet3"));
        if (dao.meta().isOracle())
          re.remove("rn");
        Pet pet = re.toPojo(Pet.class);
        assertEquals(7, re.getColumnCount());
        assertEquals(4, pet.getId());
        assertEquals("pet3", pet.getName());
        dao.create(Pet.class, true);
        dao.insert(Pet.create("中文啊中文"));
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.