.class public Lcom/alimama/tunion/trade/convert/TUnionConvertService;
.super Ljava/lang/Object;
.source "TUnionConvertService.java"


# static fields
.field private static final a:[Ljava/lang/String;

.field private static final b:[Ljava/lang/String;


# direct methods
.method static constructor <clinit>()V
    .locals 11

    const/16 v0, 0x8

    .line 36
    new-array v1, v0, [Ljava/lang/String;

    const-string v2, "taobao.com"

    const/4 v3, 0x0

    aput-object v2, v1, v3

    const-string v2, "tmall.com"

    const/4 v4, 0x1

    aput-object v2, v1, v4

    const-string v2, "alitrip.com"

    const/4 v5, 0x2

    aput-object v2, v1, v5

    const-string v2, "tmall.hk"

    const/4 v6, 0x3

    aput-object v2, v1, v6

    const-string v2, "tmall.tw"

    const/4 v7, 0x4

    aput-object v2, v1, v7

    const-string v2, "aliexpress.com"

    const/4 v8, 0x5

    aput-object v2, v1, v8

    const-string v2, "1688.com"

    const/4 v9, 0x6

    aput-object v2, v1, v9

    const-string v2, "alibaba.com"

    const/4 v10, 0x7

    aput-object v2, v1, v10

    sput-object v1, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a:[Ljava/lang/String;

    const/16 v1, 0x1e

    .line 44
    new-array v1, v1, [Ljava/lang/String;

    const-string v2, "^http[s]{0,1}:\\/\\/detail\\.tmall\\.com\\/item\\.htm"

    aput-object v2, v1, v3

    const-string v2, "^http[s]{0,1}:\\/\\/s\\.click\\.taobao\\.com\\/"

    aput-object v2, v1, v4

    const-string v2, "^http[s]{0,1}:\\/\\/global\\.click\\.taobao\\.com\\/"

    aput-object v2, v1, v5

    const-string v2, "^http[s]{0,1}:\\/\\/uland\\.taobao\\.com\\/"

    aput-object v2, v1, v6

    const-string v2, "^http[s]{0,1}:\\/\\/item\\.tmall\\.com\\/item\\.htm"

    aput-object v2, v1, v7

    const-string v2, "^http[s]{0,1}:\\/\\/item\\.taobao\\.com\\/item\\.htm"

    aput-object v2, v1, v8

    const-string v2, "^http[s]{0,1}:\\/\\/detail\\.taobao\\.com\\/item\\.htm"

    aput-object v2, v1, v9

    const-string v2, "^http[s]{0,1}:\\/\\/chaoshi\\.detail\\.tmall\\.com\\/item\\.htm"

    aput-object v2, v1, v10

    const-string v2, "^http[s]{0,1}:\\/\\/detail\\.tmall\\.hk\\/hk\\/item\\.htm"

    aput-object v2, v1, v0

    const-string v0, "^http[s]{0,1}:\\/\\/a\\.m\\.tmall\\.com\\/i\\d+\\.htm"

    const/16 v2, 0x9

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/detail\\.m\\.tmall\\.com\\/item\\.htm"

    const/16 v2, 0xa

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/a\\.m\\.taobao\\.com\\/i\\d+\\.htm"

    const/16 v2, 0xb

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/h5\\.(m|wapa)\\.taobao\\.com\\/awp\\/core\\/detail\\.htm"

    const/16 v2, 0xc

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/detail\\.m\\.tmall\\.hk\\/item\\.htm"

    const/16 v2, 0xd

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/store\\.tmall\\.com\\/shop\\/view_shop\\.htm"

    const/16 v2, 0xe

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/store\\.taobao\\.com\\/shop\\/view_shop\\.htm"

    const/16 v2, 0xf

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/shop\\.(m|wapa)\\.taobao\\.com\\/shop\\/shop_index"

    const/16 v2, 0x10

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/shop\\.(m|wapa)\\.tmall\\.com\\/shop\\/shop_index"

    const/16 v2, 0x11

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/miao\\.item\\.taobao\\.com"

    const/16 v2, 0x12

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/kezhan\\.taobao\\.com"

    const/16 v2, 0x13

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/trip\\.taobao\\.com"

    const/16 v2, 0x14

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/alitrip\\.com"

    const/16 v2, 0x15

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/ju\\.taobao\\.com"

    const/16 v2, 0x16

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/juhuasuan\\.com"

    const/16 v2, 0x17

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/aliyun\\.com"

    const/16 v2, 0x18

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/triph5\\.m\\.taobao\\.com"

    const/16 v2, 0x19

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/jp\\.m\\.taobao\\.com"

    const/16 v2, 0x1a

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/jipiao\\.m\\.taobao\\.com"

    const/16 v2, 0x1b

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/h5\\.m\\.taobao\\.com\\/trip"

    const/16 v2, 0x1c

    aput-object v0, v1, v2

    const-string v0, "^http[s]{0,1}:\\/\\/jhs\\.m\\.taobao\\.com"

    const/16 v2, 0x1d

    aput-object v0, v1, v2

    sput-object v1, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->b:[Ljava/lang/String;

    return-void
.end method

.method public constructor <init>()V
    .locals 0

    .line 34
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method

.method private a()Ljava/lang/String;
    .locals 9

    .line 271
    invoke-static {}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getInstance()Lcom/alimama/tunion/trade/TUnionTradeSDK;

    move-result-object v0

    invoke-virtual {v0}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getABTestService()Lcom/alimama/tunion/trade/abtest/TUnionABTestService;

    move-result-object v0

    const/4 v1, 0x0

    if-eqz v0, :cond_3

    const-string v2, "abtest"

    .line 274
    invoke-virtual {v0, v2}, Lcom/alimama/tunion/trade/abtest/TUnionABTestService;->getABTestValue(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v2

    .line 276
    invoke-static {v2}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v3

    const/4 v4, 0x1

    const/4 v5, 0x2

    const/4 v6, 0x0

    if-nez v3, :cond_0

    .line 277
    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    const-string v7, "abtest str(append abtest params) is "

    invoke-virtual {v3, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v3

    new-array v7, v6, [Ljava/lang/Object;

    invoke-static {v3, v7}, Lcom/alimama/tunion/utils/TULog;->d(Ljava/lang/String;[Ljava/lang/Object;)V

    .line 279
    :try_start_0
    new-instance v3, Lorg/json/JSONObject;

    invoke-direct {v3, v2}, Lorg/json/JSONObject;-><init>(Ljava/lang/String;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_1

    :try_start_1
    const-string v2, ",%s:%s"

    .line 280
    new-array v7, v5, [Ljava/lang/Object;

    const-string v8, "cid"

    aput-object v8, v7, v6

    invoke-static {}, Lcom/alimama/tunion/utils/TUnionPhoneInfoUtils;->getInstance()Lcom/alimama/tunion/utils/TUnionPhoneInfoUtils;

    move-result-object v8

    invoke-virtual {v8}, Lcom/alimama/tunion/utils/TUnionPhoneInfoUtils;->getCid()Ljava/lang/String;

    move-result-object v8

    aput-object v8, v7, v4

    invoke-static {v2, v7}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v2
    :try_end_1
    .catch Ljava/lang/Exception; {:try_start_1 .. :try_end_1} :catch_0

    move-object v1, v2

    goto :goto_1

    :catch_0
    move-exception v2

    goto :goto_0

    :catch_1
    move-exception v2

    move-object v3, v1

    .line 282
    :goto_0
    invoke-virtual {v2}, Ljava/lang/Exception;->printStackTrace()V

    goto :goto_1

    :cond_0
    move-object v3, v1

    .line 285
    :goto_1
    invoke-virtual {v0, v3}, Lcom/alimama/tunion/trade/abtest/TUnionABTestService;->getABTestCookies(Lorg/json/JSONObject;)Ljava/lang/String;

    move-result-object v0

    .line 286
    invoke-static {v1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v2

    if-nez v2, :cond_1

    :try_start_2
    const-string v2, "UTF-8"

    .line 288
    invoke-static {v1, v2}, Ljava/net/URLEncoder;->encode(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v2
    :try_end_2
    .catch Ljava/io/UnsupportedEncodingException; {:try_start_2 .. :try_end_2} :catch_2

    move-object v1, v2

    goto :goto_2

    :catch_2
    move-exception v2

    .line 290
    invoke-virtual {v2}, Ljava/io/UnsupportedEncodingException;->printStackTrace()V

    .line 293
    :cond_1
    :goto_2
    invoke-static {v1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v2

    if-nez v2, :cond_2

    const-string v2, "%s%s"

    .line 294
    new-array v3, v5, [Ljava/lang/Object;

    aput-object v0, v3, v6

    aput-object v1, v3, v4

    invoke-static {v2, v3}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v0

    return-object v0

    :cond_2
    return-object v0

    :cond_3
    return-object v1
.end method

.method static synthetic a(Lcom/alimama/tunion/trade/convert/TUnionConvertService;Ljava/lang/String;Lcom/alimama/tunion/trade/convert/TUnionJumpType;)Ljava/lang/String;
    .locals 0

    .line 34
    invoke-direct {p0, p1, p2}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a(Ljava/lang/String;Lcom/alimama/tunion/trade/convert/TUnionJumpType;)Ljava/lang/String;

    move-result-object p0

    return-object p0
.end method

.method private a(Lcom/alimama/tunion/trade/convert/TUnionJumpType;)Ljava/lang/String;
    .locals 2

    const-string v0, ""

    .line 309
    sget-object v1, Lcom/alimama/tunion/trade/convert/TUnionConvertService$2;->a:[I

    invoke-virtual {p1}, Lcom/alimama/tunion/trade/convert/TUnionJumpType;->ordinal()I

    move-result p1

    aget p1, v1, p1

    packed-switch p1, :pswitch_data_0

    goto :goto_0

    :pswitch_0
    const-string v0, "br"

    goto :goto_0

    :pswitch_1
    const-string v0, "h5"

    goto :goto_0

    :pswitch_2
    const-string v0, "tb"

    :goto_0
    return-object v0

    nop

    :pswitch_data_0
    .packed-switch 0x1
        :pswitch_2
        :pswitch_1
        :pswitch_0
    .end packed-switch
.end method

.method private a(Ljava/lang/String;Lcom/alimama/tunion/trade/convert/TUnionJumpType;)Ljava/lang/String;
    .locals 5

    .line 191
    invoke-static {p1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result p2

    if-eqz p2, :cond_0

    return-object p1

    :cond_0
    const-string p2, "^http[s]{0,1}:\\/\\/s\\.click\\.taobao\\.com\\/.*"

    .line 194
    invoke-virtual {p1, p2}, Ljava/lang/String;->matches(Ljava/lang/String;)Z

    move-result p2

    if-nez p2, :cond_1

    const-string p2, "^http[s]{0,1}:\\/\\/uland\\.taobao\\.com\\/.*"

    .line 195
    invoke-virtual {p1, p2}, Ljava/lang/String;->matches(Ljava/lang/String;)Z

    move-result p2

    if-eqz p2, :cond_3

    .line 196
    :cond_1
    invoke-direct {p0}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a()Ljava/lang/String;

    move-result-object p2

    .line 197
    invoke-static {p1}, Landroid/net/Uri;->parse(Ljava/lang/String;)Landroid/net/Uri;

    move-result-object v0

    invoke-virtual {v0}, Landroid/net/Uri;->getQuery()Ljava/lang/String;

    move-result-object v0

    .line 198
    invoke-static {p2}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v1

    if-nez v1, :cond_3

    const-string v1, "sdk_param="

    const-string v2, ""

    .line 199
    invoke-virtual {p2, v1, v2}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object p2

    .line 200
    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    const/4 v1, 0x2

    const/4 v2, 0x1

    const/4 v3, 0x0

    const/4 v4, 0x3

    if-nez v0, :cond_2

    const-string v0, "%s&%s=%s"

    .line 201
    new-array v4, v4, [Ljava/lang/Object;

    aput-object p1, v4, v3

    const-string p1, "clk1"

    aput-object p1, v4, v2

    aput-object p2, v4, v1

    invoke-static {v0, v4}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;

    move-result-object p1

    goto :goto_0

    :cond_2
    const-string v0, "%s?%s=%s"

    .line 203
    new-array v4, v4, [Ljava/lang/Object;

    aput-object p1, v4, v3

    const-string p1, "clk1"

    aput-object p1, v4, v2

    aput-object p2, v4, v1

    invoke-static {v0, v4}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;

    move-result-object p1

    :cond_3
    :goto_0
    return-object p1
.end method

.method private a(Ljava/lang/String;)Z
    .locals 1

    .line 237
    sget-object v0, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a:[Ljava/lang/String;

    invoke-static {p1, v0}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a(Ljava/lang/String;[Ljava/lang/String;)Z

    move-result p1

    return p1
.end method

.method private a(Ljava/lang/String;Lcom/alimama/tunion/trade/base/ITUnionWebView;)Z
    .locals 0

    if-eqz p2, :cond_0

    .line 220
    invoke-interface {p2}, Lcom/alimama/tunion/trade/base/ITUnionWebView;->getUrl()Ljava/lang/String;

    move-result-object p2

    goto :goto_0

    :cond_0
    const/4 p2, 0x0

    .line 222
    :goto_0
    invoke-direct {p0, p1, p2}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a(Ljava/lang/String;Ljava/lang/String;)Z

    move-result p1

    return p1
.end method

.method private a(Ljava/lang/String;Ljava/lang/String;)Z
    .locals 2

    .line 226
    invoke-static {p1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    const/4 v1, 0x0

    if-eqz v0, :cond_0

    return v1

    .line 230
    :cond_0
    invoke-direct {p0, p1}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->b(Ljava/lang/String;)Z

    move-result p1

    if-eqz p1, :cond_1

    invoke-direct {p0, p2}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a(Ljava/lang/String;)Z

    move-result p1

    if-nez p1, :cond_1

    const/4 p1, 0x1

    return p1

    :cond_1
    return v1
.end method

.method private static a(Ljava/lang/String;[Ljava/lang/String;)Z
    .locals 4

    .line 246
    invoke-static {p0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    const/4 v1, 0x0

    if-eqz v0, :cond_0

    return v1

    .line 250
    :cond_0
    array-length v0, p1

    const/4 v2, 0x0

    :goto_0
    if-ge v2, v0, :cond_2

    aget-object v3, p1, v2

    .line 252
    :try_start_0
    invoke-static {v3}, Ljava/util/regex/Pattern;->compile(Ljava/lang/String;)Ljava/util/regex/Pattern;

    move-result-object v3

    .line 253
    invoke-virtual {v3, p0}, Ljava/util/regex/Pattern;->matcher(Ljava/lang/CharSequence;)Ljava/util/regex/Matcher;

    move-result-object v3

    .line 254
    invoke-virtual {v3}, Ljava/util/regex/Matcher;->find()Z

    move-result v3
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    if-eqz v3, :cond_1

    return v3

    :catch_0
    move-exception v3

    .line 259
    invoke-virtual {v3}, Ljava/lang/Exception;->printStackTrace()V

    :cond_1
    add-int/lit8 v2, v2, 0x1

    goto :goto_0

    :cond_2
    return v1
.end method

.method private b(Ljava/lang/String;)Z
    .locals 1

    .line 242
    sget-object v0, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->b:[Ljava/lang/String;

    invoke-static {p1, v0}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a(Ljava/lang/String;[Ljava/lang/String;)Z

    move-result p1

    return p1
.end method


# virtual methods
.method public convert(Lcom/alimama/tunion/trade/convert/TUnionJumpType;Lcom/alimama/tunion/trade/base/ITUnionWebView;Ljava/lang/String;Lcom/alimama/tunion/trade/convert/TUnionMediaParams;Lcom/alimama/tunion/trade/convert/TUnionConvertCallback;)V
    .locals 3

    .line 87
    invoke-static {}, Lcom/alimama/tunion/utils/TUnionPhoneInfoUtils;->getInstance()Lcom/alimama/tunion/utils/TUnionPhoneInfoUtils;

    move-result-object v0

    invoke-virtual {v0}, Lcom/alimama/tunion/utils/TUnionPhoneInfoUtils;->initCid()V

    .line 89
    invoke-static {}, Lcom/alimama/tunion/utils/TUnionUTUtils$Convert;->convert()V

    .line 91
    invoke-static {}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getInstance()Lcom/alimama/tunion/trade/TUnionTradeSDK;

    move-result-object v0

    invoke-virtual {v0}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getTUnionCookie()Lcom/alimama/tunion/trade/base/ITUnionCookie;

    move-result-object v0

    .line 92
    invoke-direct {p0}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a()Ljava/lang/String;

    move-result-object v1

    if-eqz v0, :cond_0

    .line 93
    invoke-static {v1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v2

    if-nez v2, :cond_0

    const-string v2, ".taobao.com"

    .line 94
    invoke-interface {v0, v2, v1}, Lcom/alimama/tunion/trade/base/ITUnionCookie;->setCookie(Ljava/lang/String;Ljava/lang/String;)V

    .line 97
    :cond_0
    invoke-static {p3}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    if-eqz v0, :cond_2

    const-string p2, "URL Empty"

    .line 99
    invoke-static {p2}, Lcom/alimama/tunion/utils/TUnionUTUtils$Convert;->failed(Ljava/lang/String;)V

    if-eqz p5, :cond_1

    .line 101
    new-instance p2, Lcom/alimama/tunion/trade/convert/TUnionConvertResult;

    invoke-direct {p2, p1, p3}, Lcom/alimama/tunion/trade/convert/TUnionConvertResult;-><init>(Lcom/alimama/tunion/trade/convert/TUnionJumpType;Ljava/lang/String;)V

    invoke-interface {p5, p2}, Lcom/alimama/tunion/trade/convert/TUnionConvertCallback;->onResult(Lcom/alimama/tunion/trade/convert/TUnionConvertResult;)V

    :cond_1
    return-void

    :cond_2
    if-nez p4, :cond_3

    .line 107
    new-instance p4, Lcom/alimama/tunion/trade/convert/TUnionMediaParams;

    invoke-direct {p4}, Lcom/alimama/tunion/trade/convert/TUnionMediaParams;-><init>()V

    .line 110
    :cond_3
    invoke-virtual {p4}, Lcom/alimama/tunion/trade/convert/TUnionMediaParams;->getAdzoneId()Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    if-eqz v0, :cond_4

    .line 111
    invoke-static {}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getInstance()Lcom/alimama/tunion/trade/TUnionTradeSDK;

    move-result-object v0

    invoke-virtual {v0}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getAdzoneId()Ljava/lang/String;

    move-result-object v0

    .line 112
    invoke-virtual {p4, v0}, Lcom/alimama/tunion/trade/convert/TUnionMediaParams;->setAdzoneId(Ljava/lang/String;)V

    .line 116
    :cond_4
    invoke-static {}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getInstance()Lcom/alimama/tunion/trade/TUnionTradeSDK;

    move-result-object v0

    invoke-virtual {v0}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getABTestService()Lcom/alimama/tunion/trade/abtest/TUnionABTestService;

    move-result-object v0

    if-eqz v0, :cond_5

    .line 118
    invoke-virtual {v0, p1}, Lcom/alimama/tunion/trade/abtest/TUnionABTestService;->getJumpType(Lcom/alimama/tunion/trade/convert/TUnionJumpType;)Lcom/alimama/tunion/trade/convert/TUnionJumpType;

    move-result-object v0

    goto :goto_0

    :cond_5
    move-object v0, p1

    .line 122
    :goto_0
    invoke-direct {p0, p3, p2}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a(Ljava/lang/String;Lcom/alimama/tunion/trade/base/ITUnionWebView;)Z

    move-result p2

    if-eqz p2, :cond_7

    .line 125
    invoke-virtual {p4}, Lcom/alimama/tunion/trade/convert/TUnionMediaParams;->getExtra()Ljava/util/Map;

    move-result-object p2

    if-eqz p2, :cond_6

    .line 126
    invoke-virtual {p4}, Lcom/alimama/tunion/trade/convert/TUnionMediaParams;->getExtra()Ljava/util/Map;

    move-result-object p2

    const-string v1, "url"

    invoke-interface {p2, v1, p3}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    .line 127
    invoke-virtual {p4}, Lcom/alimama/tunion/trade/convert/TUnionMediaParams;->getExtra()Ljava/util/Map;

    move-result-object p2

    const-string v1, "jtype"

    invoke-direct {p0, p1}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a(Lcom/alimama/tunion/trade/convert/TUnionJumpType;)Ljava/lang/String;

    move-result-object p1

    invoke-interface {p2, v1, p1}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    goto :goto_1

    .line 129
    :cond_6
    new-instance p2, Ljava/util/HashMap;

    invoke-direct {p2}, Ljava/util/HashMap;-><init>()V

    const-string v1, "url"

    .line 130
    invoke-interface {p2, v1, p3}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    const-string v1, "jtype"

    .line 131
    invoke-direct {p0, p1}, Lcom/alimama/tunion/trade/convert/TUnionConvertService;->a(Lcom/alimama/tunion/trade/convert/TUnionJumpType;)Ljava/lang/String;

    move-result-object p1

    invoke-interface {p2, v1, p1}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;

    .line 132
    invoke-virtual {p4, p2}, Lcom/alimama/tunion/trade/convert/TUnionMediaParams;->setExtra(Ljava/util/Map;)V

    .line 135
    :goto_1
    invoke-static {}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getInstance()Lcom/alimama/tunion/trade/TUnionTradeSDK;

    move-result-object p1

    invoke-virtual {p1}, Lcom/alimama/tunion/trade/TUnionTradeSDK;->getTUnionNetwork()Lcom/alimama/tunion/trade/base/ITUnionNetwork;

    move-result-object p1

    if-eqz p1, :cond_7

    .line 137
    instance-of p2, p1, Lcom/alimama/tunion/trade/base/ITUnionNetworkMtop;

    invoke-static {p4, p2}, Lcom/alimama/tunion/trade/net/TUnionNetworkRequest;->createConvertRequest(Lcom/alimama/tunion/trade/convert/TUnionMediaParams;Z)Lcom/alimama/tunion/trade/net/TUnionNetworkRequest;

    move-result-object p2

    .line 138
    invoke-static {}, Lcom/alimama/tunion/utils/TUnionUTUtils$Convert;->request()V

    const-string p4, "convert is calling..."

    const/4 v1, 0x0

    .line 139
    new-array v1, v1, [Ljava/lang/Object;

    invoke-static {p4, v1}, Lcom/alimama/tunion/utils/TULog;->d(Ljava/lang/String;[Ljava/lang/Object;)V

    .line 140
    new-instance p4, Lcom/alimama/tunion/trade/convert/TUnionConvertService$1;

    invoke-direct {p4, p0, p3, v0, p5}, Lcom/alimama/tunion/trade/convert/TUnionConvertService$1;-><init>(Lcom/alimama/tunion/trade/convert/TUnionConvertService;Ljava/lang/String;Lcom/alimama/tunion/trade/convert/TUnionJumpType;Lcom/alimama/tunion/trade/convert/TUnionConvertCallback;)V

    invoke-interface {p1, p2, p4}, Lcom/alimama/tunion/trade/base/ITUnionNetwork;->sendRequest(Lcom/alimama/tunion/trade/net/TUnionNetworkRequest;Lcom/alimama/tunion/trade/net/ITUnionNetReqCallback;)V

    return-void

    :cond_7
    if-eqz p5, :cond_8

    .line 179
    new-instance p1, Lcom/alimama/tunion/trade/convert/TUnionConvertResult;

    invoke-direct {p1, v0, p3}, Lcom/alimama/tunion/trade/convert/TUnionConvertResult;-><init>(Lcom/alimama/tunion/trade/convert/TUnionJumpType;Ljava/lang/String;)V

    invoke-interface {p5, p1}, Lcom/alimama/tunion/trade/convert/TUnionConvertCallback;->onResult(Lcom/alimama/tunion/trade/convert/TUnionConvertResult;)V

    :cond_8
    return-void
.end method
