package p037.p123.p124.p134;

import androidx.work.impl.WorkDatabase;
import p037.p123.p124.p133.C2657;
import p037.p123.p124.p133.C2659;

/* JADX INFO: renamed from: މ.ޗ.ޘ.ސ.ނ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes.dex */
public class C2700 {

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

    public C2700(WorkDatabase workDatabase) {
        this.f8369 = workDatabase;
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public int m4770() {
        int iM4772;
        synchronized (C2700.class) {
            iM4772 = m4772("next_alarm_manager_id");
        }
        return iM4772;
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public int m4771(int i, int i2) {
        synchronized (C2700.class) {
            int iM4772 = m4772("next_job_scheduler_id");
            if (iM4772 < i || iM4772 > i2) {
                ((C2659) this.f8369.mo846()).m4738(new C2657("next_job_scheduler_id", i + 1));
            } else {
                i = iM4772;
            }
        }
        return i;
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final int m4772(String str) {
        this.f8369.m4479();
        try {
            Long lM4737 = ((C2659) this.f8369.mo846()).m4737(str);
            int i = 0;
            int iIntValue = lM4737 != null ? lM4737.intValue() : 0;
            if (iIntValue != Integer.MAX_VALUE) {
                i = iIntValue + 1;
            }
            ((C2659) this.f8369.mo846()).m4738(new C2657(str, i));
            this.f8369.m4484();
            return iIntValue;
        } finally {
            this.f8369.m4481();
        }
    }
}
