apkfuckery/com.discord/smali/kotlin/text/w.smali
2019-10-04 22:11:59 +02:00

253 lines
5.8 KiB
Smali

.class public Lkotlin/text/w;
.super Lkotlin/text/v;
.source "_Strings.kt"
# direct methods
.method public constructor <init>()V
.locals 0
invoke-direct {p0}, Lkotlin/text/v;-><init>()V
return-void
.end method
.method public static final a(Ljava/lang/CharSequence;II)Ljava/util/List;
.locals 2
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Ljava/lang/CharSequence;",
"II)",
"Ljava/util/List<",
"Ljava/lang/String;",
">;"
}
.end annotation
const-string v0, "$this$windowed"
invoke-static {p0, v0}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
sget-object v0, Lkotlin/text/w$a;->bpi:Lkotlin/text/w$a;
check-cast v0, Lkotlin/jvm/functions/Function1;
const/4 v1, 0x1
invoke-static {p0, p1, p2, v1, v0}, Lkotlin/text/l;->a(Ljava/lang/CharSequence;IIZLkotlin/jvm/functions/Function1;)Ljava/util/List;
move-result-object p0
return-object p0
.end method
.method public static final a(Ljava/lang/CharSequence;IIZLkotlin/jvm/functions/Function1;)Ljava/util/List;
.locals 3
.annotation system Ldalvik/annotation/Signature;
value = {
"<R:",
"Ljava/lang/Object;",
">(",
"Ljava/lang/CharSequence;",
"IIZ",
"Lkotlin/jvm/functions/Function1<",
"-",
"Ljava/lang/CharSequence;",
"+TR;>;)",
"Ljava/util/List<",
"TR;>;"
}
.end annotation
const-string p3, "$this$windowed"
invoke-static {p0, p3}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
const-string p3, "transform"
invoke-static {p4, p3}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
invoke-static {p1, p2}, Lkotlin/a/ao;->T(II)V
invoke-interface {p0}, Ljava/lang/CharSequence;->length()I
move-result p3
new-instance v0, Ljava/util/ArrayList;
add-int v1, p3, p2
add-int/lit8 v1, v1, -0x1
div-int/2addr v1, p2
invoke-direct {v0, v1}, Ljava/util/ArrayList;-><init>(I)V
const/4 v1, 0x0
:goto_0
if-ge v1, p3, :cond_1
add-int v2, v1, p1
if-le v2, p3, :cond_0
move v2, p3
:cond_0
invoke-interface {p0, v1, v2}, Ljava/lang/CharSequence;->subSequence(II)Ljava/lang/CharSequence;
move-result-object v2
invoke-interface {p4, v2}, Lkotlin/jvm/functions/Function1;->invoke(Ljava/lang/Object;)Ljava/lang/Object;
move-result-object v2
invoke-virtual {v0, v2}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
add-int/2addr v1, p2
goto :goto_0
:cond_1
check-cast v0, Ljava/util/List;
return-object v0
.end method
.method public static final b(Ljava/lang/CharSequence;I)Ljava/util/List;
.locals 1
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Ljava/lang/CharSequence;",
"I)",
"Ljava/util/List<",
"Ljava/lang/String;",
">;"
}
.end annotation
const-string v0, "$this$chunked"
invoke-static {p0, v0}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
invoke-static {p0, p1, p1}, Lkotlin/text/l;->a(Ljava/lang/CharSequence;II)Ljava/util/List;
move-result-object p0
return-object p0
.end method
.method public static final k(Ljava/lang/String;I)Ljava/lang/String;
.locals 2
const-string v0, "$this$take"
invoke-static {p0, v0}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
const/4 v0, 0x0
if-ltz p1, :cond_0
const/4 v1, 0x1
goto :goto_0
:cond_0
const/4 v1, 0x0
:goto_0
if-eqz v1, :cond_1
invoke-virtual {p0}, Ljava/lang/String;->length()I
move-result v1
invoke-static {p1, v1}, Lkotlin/ranges/c;->Z(II)I
move-result p1
invoke-virtual {p0, v0, p1}, Ljava/lang/String;->substring(II)Ljava/lang/String;
move-result-object p0
const-string p1, "(this as java.lang.Strin\u2026ing(startIndex, endIndex)"
invoke-static {p0, p1}, Lkotlin/jvm/internal/k;->g(Ljava/lang/Object;Ljava/lang/String;)V
return-object p0
:cond_1
new-instance p0, Ljava/lang/StringBuilder;
const-string v0, "Requested character count "
invoke-direct {p0, v0}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
invoke-virtual {p0, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;
const-string p1, " is less than zero."
invoke-virtual {p0, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {p0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object p0
new-instance p1, Ljava/lang/IllegalArgumentException;
invoke-virtual {p0}, Ljava/lang/Object;->toString()Ljava/lang/String;
move-result-object p0
invoke-direct {p1, p0}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
check-cast p1, Ljava/lang/Throwable;
throw p1
.end method
.method public static final m(Ljava/lang/CharSequence;)C
.locals 2
const-string v0, "$this$first"
invoke-static {p0, v0}, Lkotlin/jvm/internal/k;->h(Ljava/lang/Object;Ljava/lang/String;)V
invoke-interface {p0}, Ljava/lang/CharSequence;->length()I
move-result v0
const/4 v1, 0x0
if-nez v0, :cond_0
const/4 v0, 0x1
goto :goto_0
:cond_0
const/4 v0, 0x0
:goto_0
if-nez v0, :cond_1
invoke-interface {p0, v1}, Ljava/lang/CharSequence;->charAt(I)C
move-result p0
return p0
:cond_1
new-instance p0, Ljava/util/NoSuchElementException;
const-string v0, "Char sequence is empty."
invoke-direct {p0, v0}, Ljava/util/NoSuchElementException;-><init>(Ljava/lang/String;)V
check-cast p0, Ljava/lang/Throwable;
throw p0
.end method