apkfuckery/com.discord/smali_classes2/okhttp3/RequestBody$Companion.smali
2020-07-14 22:43:59 +00:00

199 lines
4.2 KiB
Smali

.class public final Lokhttp3/RequestBody$Companion;
.super Ljava/lang/Object;
.source "RequestBody.kt"
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Lokhttp3/RequestBody;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x19
name = "Companion"
.end annotation
# direct methods
.method public constructor <init>()V
.locals 0
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
return-void
.end method
.method public constructor <init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
.locals 0
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
return-void
.end method
.method public static c(Lokhttp3/RequestBody$Companion;Lokhttp3/MediaType;[BIII)Lokhttp3/RequestBody;
.locals 1
and-int/lit8 v0, p5, 0x4
if-eqz v0, :cond_0
const/4 p3, 0x0
:cond_0
and-int/lit8 p5, p5, 0x8
if-eqz p5, :cond_1
array-length p4, p2
:cond_1
if-eqz p2, :cond_2
invoke-virtual {p0, p2, p1, p3, p4}, Lokhttp3/RequestBody$Companion;->b([BLokhttp3/MediaType;II)Lokhttp3/RequestBody;
move-result-object p0
return-object p0
:cond_2
const-string p0, "content"
invoke-static {p0}, Li0/n/c/h;->c(Ljava/lang/String;)V
const/4 p0, 0x0
throw p0
.end method
.method public static synthetic d(Lokhttp3/RequestBody$Companion;[BLokhttp3/MediaType;III)Lokhttp3/RequestBody;
.locals 1
and-int/lit8 v0, p5, 0x1
if-eqz v0, :cond_0
const/4 p2, 0x0
:cond_0
and-int/lit8 v0, p5, 0x2
if-eqz v0, :cond_1
const/4 p3, 0x0
:cond_1
and-int/lit8 p5, p5, 0x4
if-eqz p5, :cond_2
array-length p4, p1
:cond_2
invoke-virtual {p0, p1, p2, p3, p4}, Lokhttp3/RequestBody$Companion;->b([BLokhttp3/MediaType;II)Lokhttp3/RequestBody;
move-result-object p0
return-object p0
.end method
# virtual methods
.method public final a(Ljava/lang/String;Lokhttp3/MediaType;)Lokhttp3/RequestBody;
.locals 2
const/4 v0, 0x0
if-eqz p1, :cond_1
sget-object v1, Li0/t/a;->a:Ljava/nio/charset/Charset;
if-eqz p2, :cond_0
const/4 v1, 0x1
invoke-static {p2, v0, v1}, Lokhttp3/MediaType;->b(Lokhttp3/MediaType;Ljava/nio/charset/Charset;I)Ljava/nio/charset/Charset;
move-result-object v1
if-nez v1, :cond_0
sget-object v1, Li0/t/a;->a:Ljava/nio/charset/Charset;
sget-object v0, Lokhttp3/MediaType;->g:Lokhttp3/MediaType$a;
new-instance v0, Ljava/lang/StringBuilder;
invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V
invoke-virtual {v0, p2}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
const-string p2, "; charset=utf-8"
invoke-virtual {v0, p2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object p2
invoke-static {p2}, Lokhttp3/MediaType$a;->b(Ljava/lang/String;)Lokhttp3/MediaType;
move-result-object p2
:cond_0
invoke-virtual {p1, v1}, Ljava/lang/String;->getBytes(Ljava/nio/charset/Charset;)[B
move-result-object p1
const-string v0, "(this as java.lang.String).getBytes(charset)"
invoke-static {p1, v0}, Li0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
const/4 v0, 0x0
array-length v1, p1
invoke-virtual {p0, p1, p2, v0, v1}, Lokhttp3/RequestBody$Companion;->b([BLokhttp3/MediaType;II)Lokhttp3/RequestBody;
move-result-object p1
return-object p1
:cond_1
const-string p1, "$this$toRequestBody"
invoke-static {p1}, Li0/n/c/h;->c(Ljava/lang/String;)V
throw v0
.end method
.method public final b([BLokhttp3/MediaType;II)Lokhttp3/RequestBody;
.locals 7
if-eqz p1, :cond_0
array-length v0, p1
int-to-long v1, v0
int-to-long v3, p3
int-to-long v5, p4
invoke-static/range {v1 .. v6}, Lm0/g0/b;->e(JJJ)V
new-instance v0, Lokhttp3/RequestBody$Companion$a;
invoke-direct {v0, p1, p2, p4, p3}, Lokhttp3/RequestBody$Companion$a;-><init>([BLokhttp3/MediaType;II)V
return-object v0
:cond_0
const-string p1, "$this$toRequestBody"
invoke-static {p1}, Li0/n/c/h;->c(Ljava/lang/String;)V
const/4 p1, 0x0
throw p1
.end method