[jboss-user] [EJB 3.0] - Re: Using EntityManager in a abstract super class

mnrz do-not-reply at jboss.com
Thu Oct 30 16:30:54 EDT 2008


"ALRubinger" wrote : 
  | @Resource.mappedName ?
  | 
  | S,
  | ALR

Yes, I'm thinking of something like this:


  | 
  | public abstract class GeneralDataAccessManipulator {
  | 
  |       @PersistenceContext(unitName = "common-unit")
  |       EntityManager em;
  | }
  | 
  | @Resource(mappedName = "common-unit", name="pu-cm", EntityManager.class)
  | public class AccountDataAccessManipulator extends GeneralDataAccessManipulator implements AccountDAO {
  | 
  |    //...
  | }
  | 
  | 

I've tested this but it didn't work.

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

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



More information about the jboss-user mailing list