package p138.p176.p278.p279.p284.p285;

import android.content.Context;
import android.content.SharedPreferences;
import android.preference.PreferenceManager;
import java.io.IOException;
import p138.p176.p177.p242.p246.p251.C4303;

/* JADX INFO: renamed from: ދ.ހ.ހ.֏.ޙ.֏.ހ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes.dex */
public final class C5237 {

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final SharedPreferences f15464;

    /* JADX INFO: renamed from: ؠ, reason: contains not printable characters */
    public final String f15465;

    public C5237(Context context, String str, String str2) {
        if (str == null) {
            throw new IllegalArgumentException("keysetName cannot be null");
        }
        this.f15465 = str;
        Context applicationContext = context.getApplicationContext();
        if (str2 == null) {
            this.f15464 = PreferenceManager.getDefaultSharedPreferences(applicationContext);
        } else {
            this.f15464 = applicationContext.getSharedPreferences(str2, 0);
        }
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final byte[] m8717() {
        try {
            String string = this.f15464.getString(this.f15465, null);
            if (string != null) {
                return C4303.m7194(string);
            }
            throw new IOException(String.format("can't read keyset; the pref value %s does not exist", this.f15465));
        } catch (ClassCastException | IllegalArgumentException e) {
            throw new IOException(String.format("can't read keyset; the pref value %s is not a valid hex string", this.f15465), e);
        }
    }
}
