- Forum posts: 1
Feb 2, 2017, 8:50:34 PM via Website
Feb 2, 2017 8:50:34 PM via Website
I currently developing an app with a messaging function.
Private, group and global messaging should be Implemented.
I need some help to create a database structur for this feature.
Will this work? Maybe there is a better solution available? Do I still need a ID for the Messages?(User and Groups already have a ID):
public class User {
//...
public RealmList"<"PrivateMessage">" msgs = null;
}
public class PrivateMessage {
private String Message = "";
private long Time = 0;
//getter setter
}
public class Group {
//...
public RealmList"<"GroupMessage">" msgs = null;
}
public class GroupMessage {
private String Sender = "";
private String Message = "";
private long Time = 0;
//getter setter
}
Recommended editorial content
With your consent, external content is loaded here.
By clicking on the button above, you agree that external content may be displayed to you. Personal data may be transmitted to third-party providers in the process. You can find more information about this in our Privacy Policy.