【发布时间】:2016-12-01 13:08:49
【问题描述】:
我在 Spring 中构建项目时遵循了一个教程,而 @Repository 接口 正在扩展另一个接口 JpaRepository,它为子接口添加了功能:
@Repository("myRepository")
public interface myRepository extends JpaRepository<Name, Long> {
}
在@Service 类中
@Autowired
private MyRepository myrepo;
@Transactional
public Stuff save(Stuff stuff) {
return myrepo.save(stuff);
}
我想找到“SAVE”方法的实际代码。
已下载spring-data-commons-core-1.2.1.RELEASE.jar 并反编译,但在那里找不到实现。
【问题讨论】: