- Added realracing3-community.apk (71.57 MB) - Removed 32-bit support (armeabi-v7a) - Only includes arm64-v8a libraries - Decompiled source code included - Added README-community.md with analysis
44 lines
1.1 KiB
Java
44 lines
1.1 KiB
Java
package com.mbridge.msdk.playercommon.exoplayer2.util;
|
|
|
|
/* loaded from: classes4.dex */
|
|
public final class ConditionVariable {
|
|
private boolean isOpen;
|
|
|
|
public final synchronized boolean open() {
|
|
if (this.isOpen) {
|
|
return false;
|
|
}
|
|
this.isOpen = true;
|
|
notifyAll();
|
|
return true;
|
|
}
|
|
|
|
public final synchronized boolean close() {
|
|
boolean z;
|
|
z = this.isOpen;
|
|
this.isOpen = false;
|
|
return z;
|
|
}
|
|
|
|
public final synchronized void block() throws InterruptedException {
|
|
while (!this.isOpen) {
|
|
wait();
|
|
}
|
|
}
|
|
|
|
public final synchronized boolean block(long j) throws InterruptedException {
|
|
boolean z;
|
|
long elapsedRealtime = android.os.SystemClock.elapsedRealtime();
|
|
long j2 = j + elapsedRealtime;
|
|
while (true) {
|
|
z = this.isOpen;
|
|
if (z || elapsedRealtime >= j2) {
|
|
break;
|
|
}
|
|
wait(j2 - elapsedRealtime);
|
|
elapsedRealtime = android.os.SystemClock.elapsedRealtime();
|
|
}
|
|
return z;
|
|
}
|
|
}
|