【发布时间】:2015-04-16 21:35:25
【问题描述】:
这是我的场景
public boolean contains(Book book, Page needle){
for(com.googlecode.objectify.Key<Page> hay: book.getPages()){
if( needle.getKey().equals(hay) ) return true;
}
return false;
}
所以基本上 Book 和 Page 是 @Entitys。本书包含一组页面为List<Key<Page>>。我需要查找给定书中是否存在某个页面。如何比较密钥?
【问题讨论】:
标签: google-app-engine google-cloud-datastore objectify