[jboss-user] [JBoss Seam] - Re: Help: problem with EntityHome

qzhengyy do-not-reply at jboss.com
Sun May 6 01:08:45 EDT 2007


Here is the code

  | public class FooHome extends EntityHome<Foo> {
  |     @In EntityManage em
  |     @Transactional
  |     public String persist() {
  |       getEntityManager().joinTransaction();
  |       getEntityManager().persist( getInstance() );
  |       getEntityManager().flush();
  |       assignId( PersistenceProvider.instance().getId( getInstance(), getEntityManager() ) ); // This is line 32
  |       createdMessage();
  |       return "persisted";
  |    }
  | }
  | 
PersistenceProvider.instance() == null

Thanks

Qing

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4043498#4043498

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4043498



More information about the jboss-user mailing list