JPA 2.1 and Hibernate with multiple MappedSuperclass

149 Views Asked by At

I dont know if this a error or a normal feature, but my MappedSuperclass properties arent reconized by JPA/hibernate after I use a multi hierarchy. I have those classes:

  @MappedSuperclass
  public abstract class AbstractDomain{
    private Integer userId;

    @Column
    public Integer getUserId(){
       return userId;
    }

    public void setUserId(Integer userId){
      this.userId=userId;
    }
  }

   public class Invoice extends AbstractDomain{
   }

  @Entity
  public class InvoiceEntity extends Invoice{

  }

Is that right?

0

There are 0 best solutions below