private void saveLocalSharedPrefs(String username, String password) { SharedPrefEntry entry = new SharedPrefEntry(username, password); boolean isSuccess = sharedPrefsHelper.savePersonalInfo(entry); if (isSuccess) { Logger.d("Personal information saved"); } else { Logger.d("Failed to write personal information to SharedPreferences"); } }
private void populateUi() { SharedPrefEntry sharedPrefEntry = sharedPrefsHelper.getPersonalInfo(); etUsername.setText(sharedPrefEntry.getName()); etPassword.setText(sharedPrefEntry.getPassword()); }