Code example for SharedPreferences.Editor

Methods: apply, putInt

0
		return prefs.getInt(TUTORIAL_STEP, 0);
	} 
 
	public static void incrementTutorialStep() { 
		Editor editor = prefs.edit();
		editor.putInt(TUTORIAL_STEP, getTutorialStep()+1);
		editor.apply();
	} 
 
	public static void skipTutorial() { 
		Editor editor = prefs.edit();
		editor.putInt(TUTORIAL_STEP, -1);
		editor.apply();
	} 
 
	public static final int NOTIFICATION_BEACON_RUNNING = 1;
	 
	private static void showBeaconRunningNotification() { 
		NotificationManager manager = (NotificationManager) 
				application.getSystemService(Context.NOTIFICATION_SERVICE);
Stop searching for code, let great code find you!  Add Codota to your java IDE