package j$.util;

/* compiled from: r8-map-id-d03341a5c506013191640b89b63ea5cf7ac75763b497b0603d90d740714f0f53 */
/* loaded from: classes2.dex */
public final class b0 {
    public static final b0 c = new b0();
    public final boolean a;
    public final int b;

    public b0() {
        this.a = false;
        this.b = 0;
    }

    public b0(int i) {
        this.a = true;
        this.b = i;
    }

    public final boolean equals(Object obj) {
        if (this == obj) {
            return true;
        }
        if (!(obj instanceof b0)) {
            return false;
        }
        b0 b0Var = (b0) obj;
        boolean z = b0Var.a;
        boolean z2 = this.a;
        return (z2 && z) ? this.b == b0Var.b : z2 == z;
    }

    public final int hashCode() {
        if (this.a) {
            return this.b;
        }
        return 0;
    }

    public final String toString() {
        if (!this.a) {
            return "OptionalInt.empty";
        }
        return "OptionalInt[" + this.b + "]";
    }
}
