157 lines
3.3 KiB
Smali
157 lines
3.3 KiB
Smali
.class public final Lcom/facebook/internal/NativeAppCallAttachmentStore;
|
|
.super Ljava/lang/Object;
|
|
.source "NativeAppCallAttachmentStore.java"
|
|
|
|
|
|
# static fields
|
|
.field private static final a:Ljava/lang/String; = "com.facebook.internal.m"
|
|
|
|
.field private static b:Ljava/io/File;
|
|
|
|
|
|
# direct methods
|
|
.method static constructor <clinit>()V
|
|
.locals 0
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private constructor <init>()V
|
|
.locals 0
|
|
|
|
.line 53
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static a(Ljava/util/UUID;Ljava/lang/String;)Ljava/io/File;
|
|
.locals 1
|
|
.annotation system Ldalvik/annotation/Throws;
|
|
value = {
|
|
Ljava/io/FileNotFoundException;
|
|
}
|
|
.end annotation
|
|
|
|
.line 162
|
|
invoke-static {p1}, Lcom/facebook/internal/Utility;->a(Ljava/lang/String;)Z
|
|
|
|
move-result v0
|
|
|
|
if-nez v0, :cond_1
|
|
|
|
if-nez p0, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v0, 0x0
|
|
|
|
.line 168
|
|
:try_start_0
|
|
invoke-static {p0, p1, v0}, Lcom/facebook/internal/NativeAppCallAttachmentStore;->a(Ljava/util/UUID;Ljava/lang/String;Z)Ljava/io/File;
|
|
|
|
move-result-object p0
|
|
:try_end_0
|
|
.catch Ljava/io/IOException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
return-object p0
|
|
|
|
.line 172
|
|
:catch_0
|
|
new-instance p0, Ljava/io/FileNotFoundException;
|
|
|
|
invoke-direct {p0}, Ljava/io/FileNotFoundException;-><init>()V
|
|
|
|
throw p0
|
|
|
|
.line 164
|
|
:cond_1
|
|
:goto_0
|
|
new-instance p0, Ljava/io/FileNotFoundException;
|
|
|
|
invoke-direct {p0}, Ljava/io/FileNotFoundException;-><init>()V
|
|
|
|
throw p0
|
|
.end method
|
|
|
|
.method static a(Ljava/util/UUID;Ljava/lang/String;Z)Ljava/io/File;
|
|
.locals 2
|
|
.annotation system Ldalvik/annotation/Throws;
|
|
value = {
|
|
Ljava/io/IOException;
|
|
}
|
|
.end annotation
|
|
|
|
.line 208
|
|
invoke-static {p0, p2}, Lcom/facebook/internal/NativeAppCallAttachmentStore;->a(Ljava/util/UUID;Z)Ljava/io/File;
|
|
|
|
move-result-object p0
|
|
|
|
const/4 p2, 0x0
|
|
|
|
if-nez p0, :cond_0
|
|
|
|
return-object p2
|
|
|
|
.line 214
|
|
:cond_0
|
|
:try_start_0
|
|
new-instance v0, Ljava/io/File;
|
|
|
|
const-string v1, "UTF-8"
|
|
|
|
invoke-static {p1, v1}, Ljava/net/URLEncoder;->encode(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-direct {v0, p0, p1}, Ljava/io/File;-><init>(Ljava/io/File;Ljava/lang/String;)V
|
|
:try_end_0
|
|
.catch Ljava/io/UnsupportedEncodingException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
return-object v0
|
|
|
|
:catch_0
|
|
return-object p2
|
|
.end method
|
|
|
|
.method static a(Ljava/util/UUID;Z)Ljava/io/File;
|
|
.locals 2
|
|
|
|
.line 192
|
|
sget-object v0, Lcom/facebook/internal/NativeAppCallAttachmentStore;->b:Ljava/io/File;
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
const/4 p0, 0x0
|
|
|
|
return-object p0
|
|
|
|
.line 196
|
|
:cond_0
|
|
new-instance v0, Ljava/io/File;
|
|
|
|
sget-object v1, Lcom/facebook/internal/NativeAppCallAttachmentStore;->b:Ljava/io/File;
|
|
|
|
invoke-virtual {p0}, Ljava/util/UUID;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p0
|
|
|
|
invoke-direct {v0, v1, p0}, Ljava/io/File;-><init>(Ljava/io/File;Ljava/lang/String;)V
|
|
|
|
if-eqz p1, :cond_1
|
|
|
|
.line 197
|
|
invoke-virtual {v0}, Ljava/io/File;->exists()Z
|
|
|
|
move-result p0
|
|
|
|
if-nez p0, :cond_1
|
|
|
|
.line 198
|
|
invoke-virtual {v0}, Ljava/io/File;->mkdirs()Z
|
|
|
|
:cond_1
|
|
return-object v0
|
|
.end method
|