package com.google.android.exoplayer2.source;

import com.google.android.exoplayer2.b.e;
import com.google.android.exoplayer2.k;
import com.tencent.matrix.trace.core.AppMethodBeat;

final class f$d implements l {
    final /* synthetic */ f bhd;
    final int track;

    public f$d(f fVar, int i) {
        this.bhd = fVar;
        this.track = i;
    }

    public final boolean isReady() {
        AppMethodBeat.i(95483);
        f fVar = this.bhd;
        int i = this.track;
        if (fVar.bhc || (!fVar.sd() && fVar.bgO[i].bhG.sk())) {
            AppMethodBeat.o(95483);
            return true;
        }
        AppMethodBeat.o(95483);
        return false;
    }

    public final void rW() {
    }

    public final int b(k kVar, e eVar, boolean z) {
        AppMethodBeat.i(95484);
        f fVar = this.bhd;
        int i = this.track;
        if (fVar.bgS || fVar.sd()) {
            AppMethodBeat.o(95484);
            return -3;
        }
        int a = fVar.bgO[i].a(kVar, eVar, z, fVar.bhc, fVar.bgZ);
        AppMethodBeat.o(95484);
        return a;
    }

    public final void Z(long j) {
        AppMethodBeat.i(95485);
        f fVar = this.bhd;
        k kVar = fVar.bgO[this.track];
        if (!fVar.bhc || j <= kVar.bhG.sc()) {
            kVar.g(j, true);
            AppMethodBeat.o(95485);
            return;
        }
        kVar.bhG.sm();
        AppMethodBeat.o(95485);
    }
}
