Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Realm database initialization
public class SimpleRealmApp extends Application {
private static SimpleRealmApp instance;
public void onCreate() {
instance = this;
RealmConfiguration config = new RealmConfiguration.Builder(getApplicationContext()).setModules(new SimpleRealmModule()).build();
public static SimpleRealmApp getInstance() {
return instance;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment