四虎影院 v4.1.6版本的 MD5 值为:3c86dc44d368396917a29935d39af88b

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


package s.a.b;

import android.os.Handler;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.HttpURLConnection;
import java.net.URL;

public class h {
    public static h b;
    public Handler a = new Handler();

    public class a implements Runnable {
        public final String a;
        public final e b;

        public class RunnableC0512a implements Runnable {
            public final StringBuilder a;

            public RunnableC0512a(StringBuilder sb) {
                this.a = sb;
            }

            @Override
            public void run() {
                a.this.b.a(this.a.toString());
            }
        }

        public class b implements Runnable {
            public final int a;

            public b(int i2) {
                this.a = i2;
            }

            @Override
            public void run() {
                a.this.b.b("网络失败错误码:" + this.a);
            }
        }

        public class c implements Runnable {
            public final Exception a;

            public c(Exception exc) {
                this.a = exc;
            }

            @Override
            public void run() {
                a.this.b.b(s.a.a.a.a(this.a));
            }
        }

        public a(String str, e eVar) {
            this.a = str;
            this.b = eVar;
        }

        @Override
        public void run() {
            try {
                StringBuilder sb = new StringBuilder();
                HttpURLConnection httpURLConnection = (HttpURLConnection) new URL(this.a).openConnection();
                httpURLConnection.setRequestMethod("GET");
                httpURLConnection.setDoOutput(true);
                httpURLConnection.setDoInput(true);
                httpURLConnection.setUseCaches(false);
                httpURLConnection.connect();
                int responseCode = httpURLConnection.getResponseCode();
                if (responseCode != 200) {
                    h.this.a.post(new b(responseCode));
                    return;
                }
                BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(httpURLConnection.getInputStream()));
                while (true) {
                    String readLine = bufferedReader.readLine();
                    if (readLine == null) {
                        h.this.a.post(new RunnableC0512a(sb));
                        return;
                    }
                    sb.append(readLine);
                }
            } catch (Exception e2) {
                e2.printStackTrace();
                h.this.a.post(new c(e2));
            }
        }
    }

    public class b implements Runnable {
        public final e a;
        public final Exception b;

        public b(h hVar, e eVar, Exception exc) {
            this.a = eVar;
            this.b = exc;
        }

        @Override
        public void run() {
            this.a.b(s.a.a.a.a(this.b));
        }
    }

    public static class c implements e {
        @Override
        public void a(String str) {
        }

        @Override
        public void b(String str) {
        }
    }

    public static class d implements e {
        @Override
        public void a(String str) {
        }

        @Override
        public void b(String str) {
        }
    }

    public interface e {
        void a(String str);

        void b(String str);
    }

    public static h a() {
        if (b == null) {
            b = new h();
        }
        return b;
    }

    public static void a(int i2, int i3) {
        try {
            if (s.a.a.a.f21137c == null || !s.a.a.a.f21137c.U()) {
                return;
            }
            String str = "{\"fumiId\":\"" + s.a.a.a.f21146l + "\",\"type\":\"" + i2 + "\",\"status\":\"" + i3 + "\"}";
            h a2 = a();
            c cVar = new c();
            if (a2 == null) {
                throw null;
            }
            try {
                new Thread(new i(a2, "http://47.99.219.178:233/system/data/statistics/add", str, cVar)).start();
            } catch (Exception e2) {
                e2.printStackTrace();
                s.a.a.a.a(e2);
            }
        } catch (Exception e3) {
            e3.printStackTrace();
        }
    }

    public static void a(String str, String str2, int i2, int i3) {
        try {
            if (s.a.a.a.f21137c == null || !s.a.a.a.f21137c.U()) {
                return;
            }
            a().a("http://47.99.219.178:233/zhikeTongji?zhikeId=" + str + "&beizhu=" + str2 + "&type=" + i2 + "&state=" + i3, new d());
        } catch (Exception e2) {
            e2.printStackTrace();
        }
    }

    public void a(String str, e eVar) {
        try {
            new Thread(new a(str, eVar)).start();
        } catch (Exception e2) {
            e2.printStackTrace();
            this.a.post(new b(this, eVar, e2));
        }
    }
}