Examples of loadMultiple()


Examples of org.caffinitas.mapper.core.PersistenceSession.loadMultiple()

                //

                project = session.loadOne(ProjectEntity.class, project.getId());

                // load all modules (since projectId is the partition key in ModuleEntity we can load it with one SELECT)
                List<ModuleEntity> modules = session.loadMultiple(ModuleEntity.class, project.getId());

                for (ModuleEntity module : modules)
                {
                    System.out.println("  " + module.getName());
                }
View Full Code Here

Examples of org.caffinitas.mapper.core.PersistenceSession.loadMultiple()

            instC.setCid(5);
            instC.setVal("val5");
            instC.setInhC("inhC");
            session.insert(instC);

            List<StBaseEntity> multiple = session.loadMultiple(StBaseEntity.class, 1);
            Assert.assertNotNull(multiple);
            Assert.assertEquals(multiple.size(), 5);

            List<StBaseEntity> none = session.loadMultiple(StBaseEntity.class, 0);
            Assert.assertNotNull(none);
View Full Code Here

Examples of org.caffinitas.mapper.core.PersistenceSession.loadMultiple()

            List<StBaseEntity> multiple = session.loadMultiple(StBaseEntity.class, 1);
            Assert.assertNotNull(multiple);
            Assert.assertEquals(multiple.size(), 5);

            List<StBaseEntity> none = session.loadMultiple(StBaseEntity.class, 0);
            Assert.assertNotNull(none);
            Assert.assertEquals(none.size(), 0);

        } finally {session.close();}
    }
View Full Code Here

Examples of org.caffinitas.mapper.core.PersistenceSession.loadMultiple()

            instC.setCid(5);
            instC.setVal("val5");
            instC.setInhC("inhC");
            session.insert(instC);

            List<TpcBaseEntity> multiple = session.loadMultiple(TpcBaseEntity.class, 1);
            Assert.assertNotNull(multiple);
            Assert.assertEquals(multiple.size(), 5);

            List<TpcBaseEntity> none = session.loadMultiple(TpcBaseEntity.class, 0);
            Assert.assertNotNull(none);
View Full Code Here

Examples of org.caffinitas.mapper.core.PersistenceSession.loadMultiple()

            List<TpcBaseEntity> multiple = session.loadMultiple(TpcBaseEntity.class, 1);
            Assert.assertNotNull(multiple);
            Assert.assertEquals(multiple.size(), 5);

            List<TpcBaseEntity> none = session.loadMultiple(TpcBaseEntity.class, 0);
            Assert.assertNotNull(none);
            Assert.assertEquals(none.size(), 0);

        } finally {session.close();}
    }
View Full Code Here

Examples of org.caffinitas.mapper.core.PersistenceSession.loadMultiple()

            instC.setCid(5);
            instC.setVal("val5");
            instC.setInhC("inhC");
            session.insert(instC);

            List<Tpc2BaseEntity> multiple = session.loadMultiple(Tpc2BaseEntity.class, 1);
            Assert.assertNotNull(multiple);
            Assert.assertEquals(multiple.size(), 3);

            List<Tpc2BaseEntity> none = session.loadMultiple(Tpc2BaseEntity.class, 0);
            Assert.assertNotNull(none);
View Full Code Here

Examples of org.caffinitas.mapper.core.PersistenceSession.loadMultiple()

            List<Tpc2BaseEntity> multiple = session.loadMultiple(Tpc2BaseEntity.class, 1);
            Assert.assertNotNull(multiple);
            Assert.assertEquals(multiple.size(), 3);

            List<Tpc2BaseEntity> none = session.loadMultiple(Tpc2BaseEntity.class, 0);
            Assert.assertNotNull(none);
            Assert.assertEquals(none.size(), 0);

        } finally {session.close();}
    }
View Full Code Here

Examples of org.caffinitas.mapper.core.PersistenceSession.loadMultiple()

            session.insert(inst);
            inst.setStr("bar");
            session.insert(inst);

            List<NoDataColumnsEntity> many = session.loadMultiple(NoDataColumnsEntity.class, 11);
            Assert.assertNotNull(many);
            Assert.assertEquals(many.size(), 2);
            Assert.assertEquals(many.get(0).getStr(), "bar");
            Assert.assertEquals(many.get(1).getStr(), "foo");
        } finally { session.close(); }
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.