Methods Summary |
---|
public int | create1FromFactory()
Entity1 one = new Entity1();
one.setString("oneFactory");
EntityManager m = factory1.createEntityManager();
m.persist(one);
System.out.println(one.getId());
return one.getId();
|
public int | create1FromManager()
Entity1 one = new Entity1();
one.setString("oneManager");
manager1.persist(one);
return one.getId();
|
public int | create2FromFactory()
Entity2 two = new Entity2();
two.setString("twoFactory");
EntityManager m = factory2.createEntityManager();
m.persist(two);
return two.getId();
|
public int | create2FromManager()
Entity2 two = new Entity2();
two.setString("twoManager");
manager2.persist(two);
return two.getId();
|