what-the-bank/sources/io/grpc/internal/ContextRunnable.java

26 lines
597 B
Java
Raw Permalink Normal View History

2024-07-27 18:17:47 +07:00
package io.grpc.internal;
import io.grpc.Context;
/* loaded from: classes6.dex */
abstract class ContextRunnable implements Runnable {
private final Context context;
public abstract void runInContext();
/* JADX INFO: Access modifiers changed from: protected */
public ContextRunnable(Context context) {
this.context = context;
}
@Override // java.lang.Runnable
public final void run() {
Context attach = this.context.attach();
try {
runInContext();
} finally {
this.context.detach(attach);
}
}
}