2013-02-19 108 views
0

超類中查找此:重寫返回牛逼通用父類的方法

public class DomainRepository<T> { 
    public DomainRepository(Class genericType) { 
     this.genericType = genericType; 
    } 

    @Transactional(readOnly = true) 
    public T get(final long id) { 
     return (T) sessionFactory.getCurrentSession().get(genericType, id); 
    } 
} 

子類看起來像這樣

​​

但在@覆蓋annoation sayign方法我的IDE亮點誤差不超控什麼......?

回答

4

好像Longlong不匹配。

+0

FFS。十分感謝了很多,這就是擺脫了錯誤的。將允許時接受。 – NimChimpsky 2013-02-19 11:01:37