导航菜单

页面标题

页面副标题

管控平台 v5.2.3.0. - z.java 源代码

正在查看: 管控平台 v5.2.3.0. 应用的 z.java JAVA 源代码文件

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


package com.iflytek.mdmservice.k;

import android.text.TextUtils;
import android.util.SparseArray;
import com.iflytek.mdmcommon.NetUtil;
import com.iflytek.mdmservice.MDMApp;
import java.io.IOException;
import java.util.concurrent.TimeUnit;
import okhttp3.a0;
import okhttp3.c0;
import okhttp3.v;
import okhttp3.y;
import retrofit2.m;

public class z {

    private static SparseArray<z> f259c = new SparseArray<>(1);

    private retrofit2.m f260a;

    private i0 f261b;

    class a implements okhttp3.v {
        a(z zVar) {
        }

        @Override
        public okhttp3.c0 intercept(v.a aVar) throws IOException {
            a0.a g = aVar.request().g();
            g.a("Content-Type", "application/json");
            return aVar.d(g.b());
        }
    }

    class b implements okhttp3.v {
        b(z zVar) {
        }

        @Override
        public okhttp3.c0 intercept(v.a aVar) throws IOException {
            okhttp3.a0 request = aVar.request();
            String dVar = request.b().toString();
            if (!NetUtil.isNetworkAvailable(MDMApp.j())) {
                a0.a g = request.g();
                g.c(TextUtils.isEmpty(dVar) ? okhttp3.d.n : okhttp3.d.o);
                request = g.b();
            }
            okhttp3.c0 d = aVar.d(request);
            if (NetUtil.isNetworkAvailable(MDMApp.j())) {
                c0.a M = d.M();
                M.i("Cache-Control", dVar);
                M.p("Pragma");
                return M.c();
            }
            c0.a M2 = d.M();
            M2.i("Cache-Control", "public, only-if-cached, max-stale=172800");
            M2.p("Pragma");
            return M2.c();
        }
    }

    private z() {
        a aVar = new a(this);
        b bVar = new b(this);
        y.b bVar2 = new y.b();
        bVar2.n(20000L, TimeUnit.MILLISECONDS);
        bVar2.e(20000L, TimeUnit.MILLISECONDS);
        bVar2.o(true);
        bVar2.a(bVar);
        bVar2.b(bVar);
        bVar2.a(aVar);
        okhttp3.y c2 = bVar2.c();
        com.google.gson.f fVar = new com.google.gson.f();
        fVar.e("yyyy-MM-dd'T'HH:mm:ssZ");
        fVar.d();
        com.google.gson.e b2 = fVar.b();
        m.b bVar3 = new m.b();
        bVar3.g(c2);
        bVar3.a(retrofit2.adapter.rxjava2.g.d());
        bVar3.b(retrofit2.p.a.a.d(b2));
        bVar3.c("http://jkintranet.changyan.com:8015");
        retrofit2.m e = bVar3.e();
        this.f260a = e;
        this.f261b = (i0) e.d(i0.class);
    }

    public static i0 a() {
        z zVar = f259c.get(1);
        if (zVar == null) {
            zVar = new z();
            f259c.put(1, zVar);
        }
        return zVar.f261b;
    }
}