1

我想创建多个表,并且希望能够在其中添加记录,而无需为每个表添加 Java 对象类。在 Parse 中我可以做

ParseObject gameScore = new ParseObject("GameScore");
gameScore.put("score", 1337);
gameScore.put("playerName", "Sean Plott");
gameScore.put("cheatMode", false);
gameScore.saveInBackground();

我如何使用 Backendless 做类似的事情?

4

1 回答 1

2

您可以在 Backendless 中执行此操作(asyncCallback 是 com.backendless.async.callback.AsyncCallback 的一个实例):

HashMap gameScore = new HashMap();
gameScore.put("score", 1337);
gameScore.put("playerName", "Sean Plott");
gameScore.put("cheatMode", false);
Backendless.Data.of( "GameScore" ).save( gameScore, asyncCallback );
于 2016-03-13T07:43:49.833 回答