我通过从Java项目导入一个类
import myproj.domain.ActionResponse;
然后,我尝试通过扩展Neo4jRepository为存储库创建一个接口。
我遵循以下文件:
“参数类型从
<T>
到
<T, ID>
" -
https://docs.spring.io/spring-data/neo4j/docs/current/reference/html/
@Repository
public interface ActionResponseRepository extends Neo4jRepository<ActionResponse, ActionResponse.getId() > {
...
...
@GraphId
@JsonProperty("id")
Long id;
public Long getId() {
return id;
}
...
问题
这:
extends Neo4jRepository<ActionResponse, ActionResponse.getId() >
如何用ActionResponse类的id填充第二个参数字段?