小编Fal*_*con的帖子

appengine 自动生成的 Long @id 在实体范围内是唯一的吗?

使用 objectify,我使用 App Engine 自动生成的 id 为我的实体创建 id,如下所示:

@id
Long ID;
Run Code Online (Sandbox Code Playgroud)

我在变量 ID 中设置了 null,因此 App Engine 会自动为我的实体生成 ID。

通过 objectify 函数创建密钥:

Key.create(java.lang.Class<? extends T> kindClass, long id)
Run Code Online (Sandbox Code Playgroud)

我可以得出结论,为没有任何父关系的实体自动生成的 id 是唯一的吗?

java google-app-engine objectify

2
推荐指数
1
解决办法
840
查看次数

标签 统计

google-app-engine ×1

java ×1

objectify ×1