package com.kuaishou.weapon.p0; import android.content.Context; import android.content.SharedPreferences; public class p3 { public static final String c = "plc001_t_re"; public static final String d = "wlpauct2"; public static final String e = "plc001_pd_ptip_pi"; public static final String f = "wiipaot"; public static final int g = 1; public static final String h = "a1_p_s_p_s"; public static final String i = "a1_p_s_p_s_c_b"; public static p3 j; public SharedPreferences a; public SharedPreferences.Editor b; public p3(Context context) { try { SharedPreferences sharedPreferences = context.getSharedPreferences(i1.r, 4); this.a = sharedPreferences; this.b = sharedPreferences.edit(); } catch (Throwable unused) { } } public static p3 a() { return j; } /* JADX WARNING: Code restructure failed: missing block: B:15:0x0017, code lost: return null; */ /* JADX WARNING: Exception block dominator not found, dom blocks: [] */ public static synchronized p3 a(Context context) { p3 p3Var; synchronized (p3.class) { if (j == null) { j = new p3(context); } p3Var = j; } return p3Var; } public int a(String str, int i2) { try { return this.a.getInt(str, i2); } catch (Throwable unused) { return i2; } } public String a(String str, String str2) { return this.a.getString(str, str2); } public void a(String str, int i2, boolean z) { try { this.b.putInt(str, i2); if (z) { this.b.apply(); } } catch (Throwable unused) { } } public void a(String str, long j2, boolean z) { try { this.b.putLong(str, j2); if (z) { this.b.apply(); } } catch (Throwable unused) { } } public void a(String str, Boolean bool, boolean z) { try { SharedPreferences.Editor editor = this.b; if (editor != null) { editor.putBoolean(str, bool.booleanValue()); if (z) { this.b.apply(); } } } catch (Exception unused) { } } public boolean a(String str) { return this.a.getBoolean(str, false); } public long b(String str) { return this.a.getLong(str, 0); } public void b(String str, String str2) { try { this.b.putString(str, str2); this.b.apply(); } catch (Exception unused) { } } }