导航菜单

页面标题

页面副标题

FanCode v7.24.0 - j.java 源代码

正在查看: FanCode v7.24.0 应用的 j.java JAVA 源代码文件

本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。


package jd;

import android.net.Uri;
import android.text.TextUtils;
import androidx.media3.datasource.HttpDataSource;
import androidx.media3.datasource.cronet.CronetDataSource;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.concurrent.Executor;
import org.chromium.net.CronetEngine;

public class j implements HttpDataSource {
    private static final HashMap<String, List<String>> b = new HashMap<>();
    private HttpDataSource a;

    public static final class a implements HttpDataSource.a {
        CronetDataSource.b a;

        public a(CronetEngine cronetEngine, Executor executor) {
            j.b.clear();
            this.a = new CronetDataSource.b(cronetEngine, executor);
        }

        public a b(int i) {
            this.a.b(i);
            return this;
        }

        public a c(Map<String, String> map) {
            this.a.c(map);
            return this;
        }

        public a d(boolean z) {
            this.a.d(z);
            return this;
        }

        public a e(int i) {
            this.a.e(i);
            return this;
        }

        public a f(boolean z) {
            this.a.f(z);
            return this;
        }

        public a g(String str) {
            this.a.g(str);
            return this;
        }

        public HttpDataSource m192a() {
            return new j(this.a.a());
        }
    }

    protected j(HttpDataSource httpDataSource) {
        this.a = httpDataSource;
        b("referer", "https://fancode.com/");
        HashMap<String, List<String>> hashMap = b;
        if (hashMap.containsKey("Set-Cookie")) {
            String n = n(hashMap.get("Set-Cookie"));
            b("Cookie", n);
            o(2, "setResponseHeaders", n);
        }
    }

    private String n(List<String> list) {
        if (list == null || list.isEmpty()) {
            return null;
        }
        return TextUtils.join(";", list);
    }

    public void addTransferListener(d1.l lVar) {
        this.a.addTransferListener(lVar);
    }

    public void b(String str, String str2) {
        this.a.b(str, str2);
    }

    public void close() throws HttpDataSource.HttpDataSourceException {
        this.a.close();
    }

    public Map<String, List<String>> getResponseHeaders() {
        if (this.a.getUri() != null && this.a.getResponseHeaders() != null && this.a.getResponseHeaders().get("Set-Cookie") != null) {
            o(2, "getResponseHeaders", "Uri " + this.a.getUri().toString() + " Cookie: " + ((List) this.a.getResponseHeaders().get("Set-Cookie")).toString());
            b.put("Set-Cookie", (List) this.a.getResponseHeaders().get("Set-Cookie"));
            List list = (List) this.a.getResponseHeaders().get("X-ERROR-Type");
            id.c.a.b(this.a.getUri().toString(), this.a.getResponseHeaders().toString(), this.a.h(), list != null ? list.toString() : "NA");
        }
        return this.a.getResponseHeaders();
    }

    public Uri getUri() {
        return this.a.getUri();
    }

    public int h() {
        return this.a.h();
    }

    void o(int i, String str, String str2) {
        com.fancode.video.j.e().f().log(i, "FCCronetDataSource", str + " / " + str2);
    }

    public long open(d1.f fVar) throws HttpDataSource.HttpDataSourceException {
        return this.a.open(fVar);
    }

    public int read(byte[] bArr, int i, int i2) throws HttpDataSource.HttpDataSourceException {
        return this.a.read(bArr, i, i2);
    }
}