電視直播.apk(点击下载) / b.java


package com.aliyun.vodplayer.b.f.d;

import android.content.Context;
import android.text.TextUtils;
import com.alivc.player.AliyunErrorCode;
import com.alivc.player.VcPlayerLog;
import com.aliyun.vodplayer.e.a;
import com.aliyun.vodplayer.e.c;
import com.aliyun.vodplayer.e.d;
import java.lang.ref.WeakReference;
import java.util.Map;
import org.json.JSONException;
import org.json.JSONObject;

/* compiled from: GetPlayInfoRequest */
public class b extends a {

    /* renamed from: ᐧ  reason: contains not printable characters */
    private static final String f525 = "b";

    /* renamed from: ˈ  reason: contains not printable characters */
    private WeakReference<Context> f526;

    /* renamed from: ˉ  reason: contains not printable characters */
    private String f527;

    /* renamed from: ˊ  reason: contains not printable characters */
    private String f528;

    /* renamed from: ˋ  reason: contains not printable characters */
    private String f529;

    /* renamed from: ˎ  reason: contains not printable characters */
    private String f530;

    /* renamed from: ˏ  reason: contains not printable characters */
    private String f531;

    /* renamed from: ˑ  reason: contains not printable characters */
    private String f532;

    /* renamed from: י  reason: contains not printable characters */
    private String f533;

    /* renamed from: ـ  reason: contains not printable characters */
    private String f534;

    /* renamed from: ٴ  reason: contains not printable characters */
    private c f535 = null;

    public b(Context context, String str, String str2, String str3, String str4, String str5, String str6, String str7, String str8, a.d dVar) {
        super(context, dVar);
        this.f526 = new WeakReference<>(context);
        this.f527 = str;
        this.f528 = str2;
        this.f529 = str3;
        this.f530 = str4;
        this.f531 = str5;
        this.f532 = str6;
        this.f533 = str7;
        this.f534 = str8;
    }

    @Override // com.aliyun.vodplayer.e.a
    /* renamed from: ʼ  reason: contains not printable characters */
    public void m497() {
        com.aliyun.vodplayer.d.b bVar = new com.aliyun.vodplayer.d.b(this.f530, this.f531);
        a aVar = new a(this.f528, this.f529, this.f532, this.f533, this.f534);
        com.aliyun.vodplayer.d.a aVar2 = new com.aliyun.vodplayer.d.a(this.f530, this.f531);
        Map<String, String> r2 = bVar.m611();
        r2.put("Version", "2017-03-21");
        String str = TextUtils.isEmpty(this.f527) ? "cn-shanghai" : this.f527;
        String r22 = aVar2.m608("https://vod." + str + ".aliyuncs.com/", "GET", r2, aVar.m496());
        String str2 = f525;
        VcPlayerLog.d(str2, "0824 GetPlayInfo url = " + r22);
        if (this.f598) {
            VcPlayerLog.e(f525, " fail : stop..");
            m618(-1, "", "");
            return;
        }
        try {
            this.f535 = new c(r22);
            String r23 = c.m629(r22);
            String str3 = f525;
            VcPlayerLog.d(str3, "0824 GetPlayInfo response : " + r23);
            if (TextUtils.isEmpty(r23)) {
                m618(AliyunErrorCode.ALIVC_ERR_DATA_ERROR.getCode(), AliyunErrorCode.ALIVC_ERR_DATA_ERROR.getDescription(this.f526.get()), "");
                return;
            }
            JSONObject jSONObject = new JSONObject(r23);
            String r24 = d.m642(jSONObject, "RequestId");
            if (!jSONObject.has("StatusCode") || !jSONObject.has("ResponseStr")) {
                com.aliyun.vodplayer.b.f.d.c.a r0 = com.aliyun.vodplayer.b.f.d.c.a.m499(jSONObject);
                String str4 = f525;
                VcPlayerLog.d(str4, "0824 GetPlayInfo response mediaListInfo =  " + r0 + " . size = " + r0.m502().m526().size());
                if (r0 == null) {
                    m618(AliyunErrorCode.ALIVC_ERR_DATA_ERROR.getCode(), AliyunErrorCode.ALIVC_ERR_DATA_ERROR.getDescription(this.f526.get()), r24);
                } else {
                    m619(r0, r24);
                }
            } else {
                String r02 = d.m642(jSONObject, "ResponseStr");
                String str5 = f525;
                VcPlayerLog.e(str5, "GetPlayInfo response error: " + r02);
                if (!r02.contains("Expire")) {
                    if (!r02.contains("expire")) {
                        m618(AliyunErrorCode.ALIVC_ERR_QEQUEST_SAAS_SERVER_ERROR.getCode(), AliyunErrorCode.ALIVC_ERR_QEQUEST_SAAS_SERVER_ERROR.getDescription(this.f526.get()), r24);
                        return;
                    }
                }
                m618(AliyunErrorCode.ALIVC_ERR_AUTH_EXPIRED.getCode(), AliyunErrorCode.ALIVC_ERR_AUTH_EXPIRED.getDescription(this.f526.get()), r24);
            }
        } catch (JSONException e2) {
            String str6 = f525;
            VcPlayerLog.e(str6, "e : " + e2.getMessage());
            m618(AliyunErrorCode.ALIVC_ERR_DATA_ERROR.getCode(), AliyunErrorCode.ALIVC_ERR_DATA_ERROR.getDescription(this.f526.get()), "");
        } catch (Exception e3) {
            String str7 = f525;
            VcPlayerLog.e(str7, "e : " + e3.getMessage());
            m618(AliyunErrorCode.ALIVC_ERR_NO_NETWORK.getCode(), AliyunErrorCode.ALIVC_ERR_NO_NETWORK.getDescription(this.f526.get()), "");
        }
    }

    @Override // com.aliyun.vodplayer.e.a
    /* renamed from: ʾ  reason: contains not printable characters */
    public void m498() {
        c cVar = this.f535;
        if (cVar != null) {
            cVar.m635();
        }
    }
}