2021-11-08 18:25:28 +00:00
|
|
|
package j0.l.a;
|
2021-06-27 20:44:35 +00:00
|
|
|
|
2022-01-27 00:50:41 +00:00
|
|
|
import b.d.b.a.a;
|
|
|
|
import b.i.a.f.e.o.f;
|
2021-11-08 18:25:28 +00:00
|
|
|
import j0.l.a.y1;
|
2021-06-27 20:44:35 +00:00
|
|
|
import rx.Producer;
|
2022-03-02 20:59:20 +00:00
|
|
|
/* compiled from: OperatorSwitch.java */
|
|
|
|
/* loaded from: classes3.dex */
|
2021-06-27 20:44:35 +00:00
|
|
|
public class a2 implements Producer {
|
2021-12-17 22:03:14 +00:00
|
|
|
public final /* synthetic */ y1.c j;
|
2021-06-27 20:44:35 +00:00
|
|
|
|
|
|
|
public a2(y1.c cVar) {
|
2021-12-17 22:03:14 +00:00
|
|
|
this.j = cVar;
|
2021-06-27 20:44:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
@Override // rx.Producer
|
|
|
|
public void j(long j) {
|
|
|
|
Producer producer;
|
2022-03-02 20:59:20 +00:00
|
|
|
int i = (j > 0L ? 1 : (j == 0L ? 0 : -1));
|
2021-06-27 20:44:35 +00:00
|
|
|
if (i > 0) {
|
2021-12-17 22:03:14 +00:00
|
|
|
y1.c cVar = this.j;
|
2021-06-27 20:44:35 +00:00
|
|
|
synchronized (cVar) {
|
2022-03-30 16:43:10 +00:00
|
|
|
producer = cVar.f3765s;
|
2022-01-27 00:50:41 +00:00
|
|
|
cVar.r = f.f(cVar.r, j);
|
2021-06-27 20:44:35 +00:00
|
|
|
}
|
|
|
|
if (producer != null) {
|
|
|
|
producer.j(j);
|
|
|
|
}
|
|
|
|
cVar.b();
|
|
|
|
} else if (i < 0) {
|
2022-01-27 00:50:41 +00:00
|
|
|
throw new IllegalArgumentException(a.s("n >= 0 expected but it was ", j));
|
2021-06-27 20:44:35 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|