ViMusic v0.5.4版本的 MD5 值为:e5d76df875234aa34db5af7d13eb379b

以下内容为反编译后的 a0.java 源代码,内容仅作参考


package q5;

import java.nio.charset.Charset;
import java.nio.charset.CharsetEncoder;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.Set;
public final class a0 {
    public static final e0 f9757k = q6.c.s("http://localhost");
    public c0 f9758a;
    public String f9759b;
    public int f9760c;
    public boolean f9761d;
    public String f9762e;
    public String f9763f;
    public String f9764g;
    public List f9765h;
    public x f9766i;
    public f0 f9767j;

    public a0() {
        c0 c0Var = c0.f9775c;
        o7.u uVar = o7.u.f8825q;
        w.f9833b.getClass();
        h hVar = h.f9803c;
        g7.e.z(c0Var, "protocol");
        this.f9758a = c0Var;
        this.f9759b = "";
        this.f9760c = 0;
        this.f9761d = false;
        this.f9762e = null;
        this.f9763f = null;
        Set set = b.f9768a;
        Charset charset = h8.a.f3703a;
        g7.e.z(charset, "charset");
        StringBuilder sb = new StringBuilder();
        CharsetEncoder newEncoder = charset.newEncoder();
        g7.e.y(newEncoder, "charset.newEncoder()");
        b.g(p9.e.Q(newEncoder, "", 0, "".length()), new a(false, sb, false));
        String sb2 = sb.toString();
        g7.e.y(sb2, "StringBuilder().apply(builderAction).toString()");
        this.f9764g = sb2;
        this.f9765h = new ArrayList(o7.o.G0(uVar, 10));
        y p10 = p9.e.p();
        b2.l.C(p10, hVar);
        this.f9766i = p10;
        this.f9767j = new f0(p10);
    }

    public final void a() {
        boolean z9;
        if (this.f9759b.length() > 0) {
            z9 = true;
        } else {
            z9 = false;
        }
        if (!z9 && !g7.e.n(this.f9758a.f9777a, "file")) {
            e0 e0Var = f9757k;
            this.f9759b = e0Var.f9787b;
            c0 c0Var = this.f9758a;
            c0 c0Var2 = c0.f9775c;
            if (g7.e.n(c0Var, c0.f9775c)) {
                this.f9758a = e0Var.f9786a;
            }
            if (this.f9760c == 0) {
                this.f9760c = e0Var.f9788c;
            }
        }
    }

    public final e0 b() {
        String str;
        String str2;
        a();
        c0 c0Var = this.f9758a;
        String str3 = this.f9759b;
        int i10 = this.f9760c;
        List<String> list = this.f9765h;
        ArrayList arrayList = new ArrayList(o7.o.G0(list, 10));
        for (String str4 : list) {
            arrayList.add(b.d(str4));
        }
        w U = b2.l.U(this.f9767j.f9800a);
        String e10 = b.e(this.f9764g, 0, 0, false, 15);
        String str5 = this.f9762e;
        if (str5 != null) {
            str = b.d(str5);
        } else {
            str = null;
        }
        String str6 = this.f9763f;
        if (str6 != null) {
            str2 = b.d(str6);
        } else {
            str2 = null;
        }
        return new e0(c0Var, str3, i10, arrayList, U, e10, str, str2, this.f9761d, c());
    }

    public final String c() {
        List list;
        a();
        StringBuilder sb = new StringBuilder(256);
        sb.append((CharSequence) this.f9758a.f9777a);
        String str = this.f9758a.f9777a;
        if (g7.e.n(str, "file")) {
            String str2 = this.f9759b;
            String Y = p9.e.Y(this);
            sb.append((CharSequence) "://");
            sb.append((CharSequence) str2);
            if (!h8.i.N0(Y)) {
                sb.append('/');
            }
            sb.append((CharSequence) Y);
        } else if (g7.e.n(str, "mailto")) {
            StringBuilder sb2 = new StringBuilder();
            String str3 = this.f9762e;
            String str4 = this.f9763f;
            if (str3 != null) {
                sb2.append(str3);
                if (str4 != null) {
                    sb2.append(':');
                    sb2.append(str4);
                }
                sb2.append("@");
            }
            String sb3 = sb2.toString();
            g7.e.y(sb3, "StringBuilder().apply(builderAction).toString()");
            String str5 = this.f9759b;
            sb.append((CharSequence) ":");
            sb.append((CharSequence) sb3);
            sb.append((CharSequence) str5);
        } else {
            sb.append((CharSequence) "://");
            sb.append((CharSequence) p9.e.X(this));
            String Y2 = p9.e.Y(this);
            x xVar = this.f9766i;
            boolean z9 = this.f9761d;
            g7.e.z(Y2, "encodedPath");
            g7.e.z(xVar, "encodedQueryParameters");
            boolean z10 = true;
            if ((!h8.i.x0(Y2)) && !h8.i.L0(Y2, "/", false)) {
                sb.append('/');
            }
            sb.append((CharSequence) Y2);
            if (!xVar.isEmpty() || z9) {
                sb.append((CharSequence) "?");
            }
            Set<Map.Entry> a10 = xVar.a();
            ArrayList arrayList = new ArrayList();
            for (Map.Entry entry : a10) {
                String str6 = (String) entry.getKey();
                List<String> list2 = (List) entry.getValue();
                if (list2.isEmpty()) {
                    list = f8.m.k0(new n7.f(str6, null));
                } else {
                    ArrayList arrayList2 = new ArrayList(o7.o.G0(list2, 10));
                    for (String str7 : list2) {
                        arrayList2.add(new n7.f(str6, str7));
                    }
                    list = arrayList2;
                }
                o7.q.K0(list, arrayList);
            }
            o7.s.V0(arrayList, sb, "&", c5.b.A, 60);
            if (this.f9764g.length() <= 0) {
                z10 = false;
            }
            if (z10) {
                sb.append('#');
                sb.append((CharSequence) this.f9764g);
            }
        }
        String sb4 = sb.toString();
        g7.e.y(sb4, "appendTo(StringBuilder(256)).toString()");
        return sb4;
    }
}