j.smali
.class final Lcom/appsflyer/j;
.super Ljava/lang/Object;
.source "SourceFile"
# interfaces
.implements Ljava/lang/Runnable;
# instance fields
.field private synthetic Ac:Lcom/appsflyer/e;
.field private Ai:Ljava/lang/String;
.field private Aj:Ljava/util/Map;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/Map",
"<",
"Ljava/lang/String;",
"Ljava/lang/Object;",
">;"
}
.end annotation
.end field
.field private Ak:Z
.field private Al:I
.field private zZ:Ljava/lang/ref/WeakReference;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/lang/ref/WeakReference",
"<",
"Landroid/content/Context;",
">;"
}
.end annotation
.end field
# direct methods
.method private constructor <init>(Lcom/appsflyer/e;Ljava/lang/String;Ljava/util/Map;Landroid/content/Context;ZI)V
.registers 8
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Ljava/lang/String;",
"Ljava/util/Map",
"<",
"Ljava/lang/String;",
"Ljava/lang/Object;",
">;",
"Landroid/content/Context;",
"ZI)V"
}
.end annotation
.prologue
.line 2653
iput-object p1, p0, Lcom/appsflyer/j;->Ac:Lcom/appsflyer/e;
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
.line 2644
const/4 v0, 0x0
iput-object v0, p0, Lcom/appsflyer/j;->zZ:Ljava/lang/ref/WeakReference;
.line 2654
iput-object p2, p0, Lcom/appsflyer/j;->Ai:Ljava/lang/String;
.line 2655
iput-object p3, p0, Lcom/appsflyer/j;->Aj:Ljava/util/Map;
.line 2656
new-instance v0, Ljava/lang/ref/WeakReference;
invoke-direct {v0, p4}, Ljava/lang/ref/WeakReference;-><init>(Ljava/lang/Object;)V
iput-object v0, p0, Lcom/appsflyer/j;->zZ:Ljava/lang/ref/WeakReference;
.line 2657
iput-boolean p5, p0, Lcom/appsflyer/j;->Ak:Z
.line 2658
iput p6, p0, Lcom/appsflyer/j;->Al:I
.line 2659
return-void
.end method
.method synthetic constructor <init>(Lcom/appsflyer/e;Ljava/lang/String;Ljava/util/Map;Landroid/content/Context;ZIB)V
.registers 8
.prologue
.line 2641
invoke-direct/range {p0 .. p6}, Lcom/appsflyer/j;-><init>(Lcom/appsflyer/e;Ljava/lang/String;Ljava/util/Map;Landroid/content/Context;ZI)V
return-void
.end method
# virtual methods
.method public final run()V
.registers 9
.prologue
const/4 v7, 0x0
.line 2662
.line 2664
iget-boolean v0, p0, Lcom/appsflyer/j;->Ak:Z
if-eqz v0, :cond_1f
iget v0, p0, Lcom/appsflyer/j;->Al:I
const/4 v1, 0x2
if-gt v0, v1, :cond_1f
iget-object v0, p0, Lcom/appsflyer/j;->Ac:Lcom/appsflyer/e;
.line 2666
invoke-static {v0}, Lcom/appsflyer/e;->a(Lcom/appsflyer/e;)Z
move-result v0
if-eqz v0, :cond_1f
.line 2668
iget-object v0, p0, Lcom/appsflyer/j;->Aj:Ljava/util/Map;
const-string v1, "rfr"
iget-object v2, p0, Lcom/appsflyer/j;->Ac:Lcom/appsflyer/e;
invoke-static {v2}, Lcom/appsflyer/e;->b(Lcom/appsflyer/e;)Ljava/util/Map;
move-result-object v2
invoke-interface {v0, v1, v2}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
.line 2672
:cond_1f
:try_start_1f
iget-object v0, p0, Lcom/appsflyer/j;->Aj:Ljava/util/Map;
const-string v1, "appsflyerKey"
invoke-interface {v0, v1}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
move-result-object v3
check-cast v3, Ljava/lang/String;
.line 2674
iget-object v1, p0, Lcom/appsflyer/j;->Aj:Ljava/util/Map;
.line 3016
sget v0, Landroid/os/Build$VERSION;->SDK_INT:I
const/16 v2, 0x13
if-lt v0, v2, :cond_47
.line 3017
new-instance v0, Lorg/json/JSONObject;
invoke-direct {v0, v1}, Lorg/json/JSONObject;-><init>(Ljava/util/Map;)V
.line 2674
:goto_36
invoke-virtual {v0}, Lorg/json/JSONObject;->toString()Ljava/lang/String;
:try_end_39
.catch Ljava/io/IOException; {:try_start_1f .. :try_end_39} :catch_4c
.catch Ljava/lang/Throwable; {:try_start_1f .. :try_end_39} :catch_fe
move-result-object v2
.line 2676
:try_start_3a
iget-object v0, p0, Lcom/appsflyer/j;->Ac:Lcom/appsflyer/e;
iget-object v1, p0, Lcom/appsflyer/j;->Ai:Ljava/lang/String;
iget-object v4, p0, Lcom/appsflyer/j;->zZ:Ljava/lang/ref/WeakReference;
const/4 v5, 0x0
iget-boolean v6, p0, Lcom/appsflyer/j;->Ak:Z
invoke-static/range {v0 .. v6}, Lcom/appsflyer/e;->a(Lcom/appsflyer/e;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/ref/WeakReference;Ljava/lang/String;Z)V
:try_end_46
.catch Ljava/io/IOException; {:try_start_3a .. :try_end_46} :catch_110
.catch Ljava/lang/Throwable; {:try_start_3a .. :try_end_46} :catch_fe
.line 2687
:cond_46
:goto_46
return-void
.line 3019
:cond_47
:try_start_47
invoke-static {v1}, Lcom/appsflyer/b;->a(Ljava/util/Map;)Lorg/json/JSONObject;
:try_end_4a
.catch Ljava/io/IOException; {:try_start_47 .. :try_end_4a} :catch_4c
.catch Ljava/lang/Throwable; {:try_start_47 .. :try_end_4a} :catch_fe
move-result-object v0
goto :goto_36
.line 2678
:catch_4c
move-exception v0
move-object v1, v0
move-object v2, v7
.line 2679
:goto_4f
invoke-static {v1}, Lcom/appsflyer/AFLogger;->a(Ljava/lang/Throwable;)V
.line 2680
if-eqz v2, :cond_46
iget-object v0, p0, Lcom/appsflyer/j;->zZ:Ljava/lang/ref/WeakReference;
if-eqz v0, :cond_46
iget-object v0, p0, Lcom/appsflyer/j;->Ai:Ljava/lang/String;
const-string v3, "&isCachedRequest=true&timeincache="
invoke-virtual {v0, v3}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z
move-result v0
if-nez v0, :cond_46
.line 2681
invoke-static {}, Lcom/appsflyer/a/a;->cK()Lcom/appsflyer/a/a;
new-instance v3, Lcom/appsflyer/a/b;
iget-object v0, p0, Lcom/appsflyer/j;->Ai:Ljava/lang/String;
const-string v4, "4.8.6"
invoke-direct {v3, v0, v2, v4}, Lcom/appsflyer/a/b;-><init>(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
iget-object v0, p0, Lcom/appsflyer/j;->zZ:Ljava/lang/ref/WeakReference;
invoke-virtual {v0}, Ljava/lang/ref/WeakReference;->get()Ljava/lang/Object;
move-result-object v0
check-cast v0, Landroid/content/Context;
.line 3055
:try_start_76
invoke-static {v0}, Lcom/appsflyer/a/a;->C(Landroid/content/Context;)Ljava/io/File;
move-result-object v2
.line 3056
invoke-virtual {v2}, Ljava/io/File;->exists()Z
move-result v4
if-nez v4, :cond_8a
.line 3058
invoke-virtual {v2}, Ljava/io/File;->mkdir()Z
:try_end_83
.catch Ljava/lang/Exception; {:try_start_76 .. :try_end_83} :catch_ee
.catchall {:try_start_76 .. :try_end_83} :catchall_f7
.line 2682
:cond_83
:goto_83
invoke-virtual {v1}, Ljava/io/IOException;->getMessage()Ljava/lang/String;
invoke-static {v1}, Lcom/appsflyer/AFLogger;->a(Ljava/lang/Throwable;)V
goto :goto_46
.line 3061
:cond_8a
:try_start_8a
invoke-virtual {v2}, Ljava/io/File;->listFiles()[Ljava/io/File;
move-result-object v2
.line 3062
if-eqz v2, :cond_95
array-length v2, v2
const/16 v4, 0x28
if-gt v2, v4, :cond_83
.line 3067
:cond_95
new-instance v2, Ljava/io/File;
invoke-static {v0}, Lcom/appsflyer/a/a;->C(Landroid/content/Context;)Ljava/io/File;
move-result-object v0
invoke-static {}, Ljava/lang/System;->currentTimeMillis()J
move-result-wide v4
invoke-static {v4, v5}, Ljava/lang/Long;->toString(J)Ljava/lang/String;
move-result-object v4
invoke-direct {v2, v0, v4}, Ljava/io/File;-><init>(Ljava/io/File;Ljava/lang/String;)V
.line 3068
invoke-virtual {v2}, Ljava/io/File;->createNewFile()Z
.line 3069
new-instance v0, Ljava/io/OutputStreamWriter;
new-instance v4, Ljava/io/FileOutputStream;
invoke-virtual {v2}, Ljava/io/File;->getPath()Ljava/lang/String;
move-result-object v2
const/4 v5, 0x1
invoke-direct {v4, v2, v5}, Ljava/io/FileOutputStream;-><init>(Ljava/lang/String;Z)V
invoke-direct {v0, v4}, Ljava/io/OutputStreamWriter;-><init>(Ljava/io/OutputStream;)V
:try_end_b8
.catch Ljava/lang/Exception; {:try_start_8a .. :try_end_b8} :catch_ee
.catchall {:try_start_8a .. :try_end_b8} :catchall_f7
.line 3070
:try_start_b8
const-string v2, "version="
invoke-virtual {v0, v2}, Ljava/io/OutputStreamWriter;->write(Ljava/lang/String;)V
.line 4040
iget-object v2, v3, Lcom/appsflyer/a/b;->version:Ljava/lang/String;
.line 3071
invoke-virtual {v0, v2}, Ljava/io/OutputStreamWriter;->write(Ljava/lang/String;)V
.line 3072
const/16 v2, 0xa
invoke-virtual {v0, v2}, Ljava/io/OutputStreamWriter;->write(I)V
.line 3074
const-string v2, "url="
invoke-virtual {v0, v2}, Ljava/io/OutputStreamWriter;->write(Ljava/lang/String;)V
.line 4056
iget-object v2, v3, Lcom/appsflyer/a/b;->AD:Ljava/lang/String;
.line 3075
invoke-virtual {v0, v2}, Ljava/io/OutputStreamWriter;->write(Ljava/lang/String;)V
.line 3076
const/16 v2, 0xa
invoke-virtual {v0, v2}, Ljava/io/OutputStreamWriter;->write(I)V
.line 3078
const-string v2, "data="
invoke-virtual {v0, v2}, Ljava/io/OutputStreamWriter;->write(Ljava/lang/String;)V
.line 5048
iget-object v2, v3, Lcom/appsflyer/a/b;->AC:Ljava/lang/String;
.line 3079
invoke-virtual {v0, v2}, Ljava/io/OutputStreamWriter;->write(Ljava/lang/String;)V
.line 3080
const/16 v2, 0xa
invoke-virtual {v0, v2}, Ljava/io/OutputStreamWriter;->write(I)V
.line 3082
invoke-virtual {v0}, Ljava/io/OutputStreamWriter;->flush()V
:try_end_e8
.catch Ljava/lang/Exception; {:try_start_b8 .. :try_end_e8} :catch_10d
.catchall {:try_start_b8 .. :try_end_e8} :catchall_109
.line 3089
:try_start_e8
invoke-virtual {v0}, Ljava/io/OutputStreamWriter;->close()V
:try_end_eb
.catch Ljava/io/IOException; {:try_start_e8 .. :try_end_eb} :catch_ec
goto :goto_83
.line 3093
:catch_ec
move-exception v0
goto :goto_83
:catch_ee
move-exception v0
.line 3088
:goto_ef
if-eqz v7, :cond_83
.line 3089
:try_start_f1
invoke-virtual {v7}, Ljava/io/OutputStreamWriter;->close()V
:try_end_f4
.catch Ljava/io/IOException; {:try_start_f1 .. :try_end_f4} :catch_f5
goto :goto_83
.line 3093
:catch_f5
move-exception v0
goto :goto_83
.line 3087
:catchall_f7
move-exception v0
.line 3088
:goto_f8
if-eqz v7, :cond_fd
.line 3089
:try_start_fa
invoke-virtual {v7}, Ljava/io/OutputStreamWriter;->close()V
:try_end_fd
.catch Ljava/io/IOException; {:try_start_fa .. :try_end_fd} :catch_107
.line 3092
:cond_fd
:goto_fd
throw v0
.line 2684
:catch_fe
move-exception v0
.line 2685
invoke-virtual {v0}, Ljava/lang/Throwable;->getMessage()Ljava/lang/String;
invoke-static {v0}, Lcom/appsflyer/AFLogger;->a(Ljava/lang/Throwable;)V
goto/16 :goto_46
:catch_107
move-exception v1
goto :goto_fd
.line 3087
:catchall_109
move-exception v1
move-object v7, v0
move-object v0, v1
goto :goto_f8
:catch_10d
move-exception v2
move-object v7, v0
goto :goto_ef
.line 2678
:catch_110
move-exception v0
move-object v1, v0
goto/16 :goto_4f
.end method