简体   繁体   中英

How to prevent from an object's property from being sent and created at Backendless

I have object model in backendless app, the schema:

public class Message{

    public  String objectId;
    private long created_at;
    private String sender,receiver,text;
    public boolean isSearched;
    ...
}

i don't want to create the column "isSearched" in the database, how can i do that?

i tried to use transient with the implementation of Serializable before the public declaration:

public class Message implements Serializable{

  public  String objectId;
  private long created_at;
  private String sender,receiver,text;
  transient public boolean isSearched;
}

but still when i execute the save method like so:

Backendless.Persistence.save( new Message(...), new AsyncCallback<Message>())

the column Searched is created at the DB.

Any suggestions?

Disable Dynamic User Definition in the console. 在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM