a.smali
.class public Lcom/ksad/download/d/a;
.super Ljava/lang/Object;
# direct methods
.method public static a(Ljava/lang/String;)J
.registers 5
new-instance v0, Landroid/os/StatFs;
invoke-direct {v0, p0}, Landroid/os/StatFs;-><init>(Ljava/lang/String;)V
sget v1, Landroid/os/Build$VERSION;->SDK_INT:I
const/16 v2, 0x12
if-lt v1, v2, :cond_14
:try_start_b
invoke-virtual {v0}, Landroid/os/StatFs;->getAvailableBytes()J
:try_end_e
.catch Ljava/lang/Throwable; {:try_start_b .. :try_end_e} :catch_10
move-result-wide v0
:goto_f
return-wide v0
:catch_10
move-exception v1
invoke-virtual {v1}, Ljava/lang/Throwable;->printStackTrace()V
:cond_14
invoke-virtual {v0}, Landroid/os/StatFs;->getBlockSize()I
move-result v1
int-to-long v2, v1
invoke-virtual {v0}, Landroid/os/StatFs;->getAvailableBlocks()I
move-result v0
int-to-long v0, v0
mul-long/2addr v0, v2
goto :goto_f
.end method
.method public static a(Ljava/io/File;)Z
.registers 2
if-eqz p0, :cond_a
invoke-virtual {p0}, Ljava/io/File;->exists()Z
move-result v0
if-eqz v0, :cond_a
const/4 v0, 0x1
:goto_9
return v0
:cond_a
const/4 v0, 0x0
goto :goto_9
.end method
.method public static b(Ljava/lang/String;)Ljava/lang/String;
.registers 2
invoke-static {p0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z
move-result v0
if-eqz v0, :cond_9
const-string v0, ""
:goto_8
return-object v0
:cond_9
const/16 v0, 0x2e
invoke-virtual {p0, v0}, Ljava/lang/String;->lastIndexOf(I)I
move-result v0
if-ltz v0, :cond_18
add-int/lit8 v0, v0, 0x1
invoke-virtual {p0, v0}, Ljava/lang/String;->substring(I)Ljava/lang/String;
move-result-object v0
goto :goto_8
:cond_18
const-string v0, ""
goto :goto_8
.end method