Qas*_*har 9 spring-mvc mongodb spring-data spring-data-mongodb
我想引用嵌套对象存在于另一个Collection对象中,在我的Event对象中,这样当我得到User的事件而不是Venue of Event将用它检索时,我是mongodb中的新手,spring可以帮助你做任何事情.
class User{
private String name;
private Venue venue;
//Getter and Setter
}
class Event {
@DBRef
private Venue venue;
//Getter and Setter
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
385 次 |
| 最近记录: |