165 lines
4.5 KiB
Java
165 lines
4.5 KiB
Java
package c.i.a.f.i.b;
|
|
|
|
import android.os.Bundle;
|
|
/* compiled from: com.google.android.gms:play-services-measurement-impl@@18.0.0 */
|
|
public final class d {
|
|
public static final d a = new d(null, null);
|
|
public final Boolean b;
|
|
|
|
/* renamed from: c reason: collision with root package name */
|
|
public final Boolean f1142c;
|
|
|
|
public d(Boolean bool, Boolean bool2) {
|
|
this.b = bool;
|
|
this.f1142c = bool2;
|
|
}
|
|
|
|
public static int a(Boolean bool) {
|
|
if (bool == null) {
|
|
return 0;
|
|
}
|
|
return bool.booleanValue() ? 1 : 2;
|
|
}
|
|
|
|
/* JADX WARNING: Removed duplicated region for block: B:12:0x0026 */
|
|
public static d b(String str) {
|
|
Boolean bool;
|
|
Boolean bool2;
|
|
Boolean bool3;
|
|
Boolean bool4 = null;
|
|
if (str != null) {
|
|
if (str.length() >= 3) {
|
|
char charAt = str.charAt(2);
|
|
if (charAt == '0') {
|
|
bool2 = Boolean.FALSE;
|
|
} else if (charAt == '1') {
|
|
bool2 = Boolean.TRUE;
|
|
}
|
|
if (str.length() >= 4) {
|
|
char charAt2 = str.charAt(3);
|
|
if (charAt2 == '0') {
|
|
bool3 = Boolean.FALSE;
|
|
} else if (charAt2 == '1') {
|
|
bool3 = Boolean.TRUE;
|
|
}
|
|
bool4 = bool3;
|
|
}
|
|
bool = bool4;
|
|
bool4 = bool2;
|
|
}
|
|
bool2 = null;
|
|
if (str.length() >= 4) {
|
|
}
|
|
bool = bool4;
|
|
bool4 = bool2;
|
|
} else {
|
|
bool = null;
|
|
}
|
|
return new d(bool4, bool);
|
|
}
|
|
|
|
public static Boolean c(Boolean bool, Boolean bool2) {
|
|
if (bool == null) {
|
|
return bool2;
|
|
}
|
|
if (bool2 == null) {
|
|
return bool;
|
|
}
|
|
return Boolean.valueOf(bool.booleanValue() && bool2.booleanValue());
|
|
}
|
|
|
|
public static boolean e(int i, int i2) {
|
|
return i <= i2;
|
|
}
|
|
|
|
public static d g(Bundle bundle) {
|
|
return bundle == null ? a : new d(i(bundle.getString("ad_storage")), i(bundle.getString("analytics_storage")));
|
|
}
|
|
|
|
public static Boolean i(String str) {
|
|
if (str == null) {
|
|
return null;
|
|
}
|
|
if (str.equals("granted")) {
|
|
return Boolean.TRUE;
|
|
}
|
|
if (str.equals("denied")) {
|
|
return Boolean.FALSE;
|
|
}
|
|
return null;
|
|
}
|
|
|
|
public final String d() {
|
|
StringBuilder sb = new StringBuilder("G1");
|
|
Boolean bool = this.b;
|
|
char c2 = '0';
|
|
sb.append(bool == null ? '-' : bool.booleanValue() ? '1' : '0');
|
|
Boolean bool2 = this.f1142c;
|
|
if (bool2 == null) {
|
|
c2 = '-';
|
|
} else if (bool2.booleanValue()) {
|
|
c2 = '1';
|
|
}
|
|
sb.append(c2);
|
|
return sb.toString();
|
|
}
|
|
|
|
public final boolean equals(Object obj) {
|
|
if (!(obj instanceof d)) {
|
|
return false;
|
|
}
|
|
d dVar = (d) obj;
|
|
return a(this.b) == a(dVar.b) && a(this.f1142c) == a(dVar.f1142c);
|
|
}
|
|
|
|
public final boolean f(d dVar) {
|
|
Boolean bool = this.b;
|
|
Boolean bool2 = Boolean.FALSE;
|
|
if (bool != bool2 || dVar.b == bool2) {
|
|
return this.f1142c == bool2 && dVar.f1142c != bool2;
|
|
}
|
|
return true;
|
|
}
|
|
|
|
public final d h(d dVar) {
|
|
return new d(c(this.b, dVar.b), c(this.f1142c, dVar.f1142c));
|
|
}
|
|
|
|
public final int hashCode() {
|
|
return a(this.f1142c) + ((a(this.b) + 527) * 31);
|
|
}
|
|
|
|
public final boolean j() {
|
|
Boolean bool = this.b;
|
|
return bool == null || bool.booleanValue();
|
|
}
|
|
|
|
public final boolean k() {
|
|
Boolean bool = this.f1142c;
|
|
return bool == null || bool.booleanValue();
|
|
}
|
|
|
|
public final String toString() {
|
|
StringBuilder sb = new StringBuilder("ConsentSettings: ");
|
|
sb.append("adStorage=");
|
|
Boolean bool = this.b;
|
|
String str = "granted";
|
|
if (bool == null) {
|
|
sb.append("uninitialized");
|
|
} else {
|
|
sb.append(bool.booleanValue() ? str : "denied");
|
|
}
|
|
sb.append(", analyticsStorage=");
|
|
Boolean bool2 = this.f1142c;
|
|
if (bool2 == null) {
|
|
sb.append("uninitialized");
|
|
} else {
|
|
if (!bool2.booleanValue()) {
|
|
str = "denied";
|
|
}
|
|
sb.append(str);
|
|
}
|
|
return sb.toString();
|
|
}
|
|
}
|