what-the-bank/sources/o/fTR.java

75 lines
1.9 KiB
Java
Raw Normal View History

2024-07-27 18:17:47 +07:00
package o;
/* loaded from: classes6.dex */
public final class fTR<T> implements InterfaceC13174fSv<T>, fSJ {
private fSQ<? super fSJ> a;
private InterfaceC13174fSv<? super T> c;
private fSJ d;
private fSP e;
public fTR(InterfaceC13174fSv<? super T> interfaceC13174fSv, fSQ<? super fSJ> fsq, fSP fsp) {
this.c = interfaceC13174fSv;
this.a = fsq;
this.e = fsp;
}
@Override // o.InterfaceC13174fSv
public final void onSubscribe(fSJ fsj) {
try {
this.a.c(fsj);
if (EnumC13192fTf.d(this.d, fsj)) {
this.d = fsj;
this.c.onSubscribe(this);
}
} catch (Throwable th) {
C13147fSI.c(th);
fsj.dispose();
this.d = EnumC13192fTf.DISPOSED;
EnumC13195fTi.a(th, this.c);
}
}
@Override // o.InterfaceC13174fSv
public final void onNext(T t) {
this.c.onNext(t);
}
@Override // o.InterfaceC13174fSv
public final void onError(Throwable th) {
if (this.d != EnumC13192fTf.DISPOSED) {
this.d = EnumC13192fTf.DISPOSED;
this.c.onError(th);
} else {
C13418fZu.c(th);
}
}
@Override // o.InterfaceC13174fSv
public final void onComplete() {
if (this.d != EnumC13192fTf.DISPOSED) {
this.d = EnumC13192fTf.DISPOSED;
this.c.onComplete();
}
}
@Override // o.fSJ
public final void dispose() {
fSJ fsj = this.d;
if (fsj != EnumC13192fTf.DISPOSED) {
this.d = EnumC13192fTf.DISPOSED;
try {
this.e.c();
} catch (Throwable th) {
C13147fSI.c(th);
C13418fZu.c(th);
}
fsj.dispose();
}
}
@Override // o.fSJ
public final boolean isDisposed() {
return this.d.isDisposed();
}
}