package com.google.android.play.core.b;

import com.bytedance.covode.number.Covode;
import com.bytedance.frameworks.apm.trace.MethodCollector;
import java.nio.ByteBuffer;
import java.security.MessageDigest;

public final class v implements av {
    public final ByteBuffer LIZ;

    static {
        Covode.recordClassIndex(44303);
    }

    public v(ByteBuffer byteBuffer) {
        this.LIZ = byteBuffer.slice();
    }

    public final long LIZ() {
        return (long) this.LIZ.capacity();
    }

    public final void LIZ(MessageDigest[] messageDigestArr, long j, int i) {
        ByteBuffer slice;
        MethodCollector.i(17743);
        synchronized (this.LIZ) {
            try {
                int i2 = (int) j;
                this.LIZ.position(i2);
                this.LIZ.limit(i2 + i);
                slice = this.LIZ.slice();
            } finally {
                MethodCollector.o(17743);
            }
        }
        for (MessageDigest update : messageDigestArr) {
            slice.position(0);
            update.update(slice);
        }
    }
}
