<commit_before>package com.noprestige.kanaquiz;

import android.content.Context;
import android.content.SharedPreferences;
import android.preference.PreferenceManager;

abstract class OptionsControl
{
    final static String CODE_HIRAGANA_1 = "hiragana_set_1";
    final static String CODE_HIRAGANA_2 = "hiragana_set_2";
    final static String CODE_HIRAGANA_3 = "hiragana_set_3";
    final static String CODE_HIRAGANA_4 = "hiragana_set_4";
    final static String CODE_HIRAGANA_5 = "hiragana_set_5";
    final static String CODE_HIRAGANA_6 = "hiragana_set_6";
    final static String CODE_HIRAGANA_7 = "hiragana_set_7";
    final static String CODE_HIRAGANA_8 = "hiragana_set_8";
    final static String CODE_HIRAGANA_9 = "hiragana_set_9";
    final static String CODE_HIRAGANA_10 = "hiragana_set_10";

    final static String CODE_KATAKANA_1 = "katakana_set_1";
    final static String CODE_KATAKANA_2 = "katakana_set_2";
    final static String CODE_KATAKANA_3 = "katakana_set_3";
    final static String CODE_KATAKANA_4 = "katakana_set_4";
    final static String CODE_KATAKANA_5 = "katakana_set_5";
    final static String CODE_KATAKANA_6 = "katakana_set_6";
    final static String CODE_KATAKANA_7 = "katakana_set_7";
    final static String CODE_KATAKANA_8 = "katakana_set_8";
    final static String CODE_KATAKANA_9 = "katakana_set_9";
    final static String CODE_KATAKANA_10 = "katakana_set_10";

    final static String CODE_ON_INCORRECT_CHEAT = "show_answer_on_incorrect";
    final static String CODE_ON_INCORRECT_RETRY = "retry_on_incorrect";

    static private SharedPreferences sharedPreferences;
    static private SharedPreferences.Editor editor;

    static void initialize(Context context)
    {
        sharedPreferences = PreferenceManager.getDefaultSharedPreferences(context);
        editor = sharedPreferences.edit();
    }

    static boolean getBoolean(String prefId)
    {
        return sharedPreferences.getBoolean(prefId, false);
    }

    static void setBoolean(String prefId, boolean setting)
    {
        editor.putBoolean(prefId, setting);
        editor.apply();
    }
}
<commit_msg>Expanded context in OptionsControl<commit_after>package com.noprestige.kanaquiz;

import android.content.Context;
import android.content.SharedPreferences;
import android.preference.PreferenceManager;

abstract class OptionsControl
{
    final static String CODE_HIRAGANA_1 = "hiragana_set_1";
    final static String CODE_HIRAGANA_2 = "hiragana_set_2";
    final static String CODE_HIRAGANA_3 = "hiragana_set_3";
    final static String CODE_HIRAGANA_4 = "hiragana_set_4";
    final static String CODE_HIRAGANA_5 = "hiragana_set_5";
    final static String CODE_HIRAGANA_6 = "hiragana_set_6";
    final static String CODE_HIRAGANA_7 = "hiragana_set_7";
    final static String CODE_HIRAGANA_8 = "hiragana_set_8";
    final static String CODE_HIRAGANA_9 = "hiragana_set_9";
    final static String CODE_HIRAGANA_10 = "hiragana_set_10";

    final static String CODE_KATAKANA_1 = "katakana_set_1";
    final static String CODE_KATAKANA_2 = "katakana_set_2";
    final static String CODE_KATAKANA_3 = "katakana_set_3";
    final static String CODE_KATAKANA_4 = "katakana_set_4";
    final static String CODE_KATAKANA_5 = "katakana_set_5";
    final static String CODE_KATAKANA_6 = "katakana_set_6";
    final static String CODE_KATAKANA_7 = "katakana_set_7";
    final static String CODE_KATAKANA_8 = "katakana_set_8";
    final static String CODE_KATAKANA_9 = "katakana_set_9";
    final static String CODE_KATAKANA_10 = "katakana_set_10";

    final static String CODE_ON_INCORRECT_CHEAT = "show_answer_on_incorrect";
    final static String CODE_ON_INCORRECT_RETRY = "retry_on_incorrect";

    static private SharedPreferences sharedPreferences;
    static private SharedPreferences.Editor editor;

    static void initialize(Context context)
    {
        sharedPreferences = PreferenceManager.getDefaultSharedPreferences(context.getApplicationContext());
        editor = sharedPreferences.edit();
    }

    static boolean getBoolean(String prefId)
    {
        return sharedPreferences.getBoolean(prefId, false);
    }

    static void setBoolean(String prefId, boolean setting)
    {
        editor.putBoolean(prefId, setting);
        editor.apply();
    }
}

{'fraction_non_alphanumeric': 0.06831429237584519, 'fraction_numerical': 0.02051760317090231, 'mean_word_length': 4.6225425950196595, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2651320', 'n_tokens_mistral': 1524, 'n_tokens_neox': 1415, 'n_words': 309}