public App(params INinjectModule[] patformModules)
        {
            InitializeComponent();
            var mainPage = new NavigationPage(new MainPage());

            // setup and get an instance to our current Realm
            CurrentRealm = Realms.Realm.GetInstance(new RealmConfiguration
            {
                SchemaVersion     = RealmConfigure.SchemaVersion,
                MigrationCallback = RealmConfigure.MigrationCallback,
            });

            CurrentRealm.Write(() =>
            {
                CurrentRealm.RemoveAll();
            });

            // Register all the our core services with the kernal
            Kernal = new StandardKernel(new CoreModule(), new NavigationModule(mainPage.Navigation));
            // Register all of our platform specific modules with the kernal
            Kernal.Load(patformModules);

            mainPage.BindingContext = Kernal.Get <MainViewModel>();
            MainPage = mainPage;
        }
 public void RemoveAll()
 {
     ConfigureInstance();
     _realm.Write(() => { _realm.RemoveAll(); });
 }