コード例 #1
0
 @Test
 public void hibernateFetch() {
   System.out.println("hibernateFetch");
   BonsHotels bh = (BonsHotels) session.get(BonsHotels.class, id);
   float quotaFixaObtinguda = bh.getQuotaFixa();
   assertEquals(quotaFixaObtinguda, quotaFixa, 0.0);
 }
コード例 #2
0
 private void carregaBonsHotels() {
   BonsHotels bh = new BonsHotels();
   bh.setId(1);
   bh.setQuotaFixa(0.05F);
   bh.setQuotaVariable(0.07F);
   session.persist(bh);
 }