137 lines
4.5 KiB
Smali
137 lines
4.5 KiB
Smali
.class public final Lcom/discord/utilities/textprocessing/Rules$createUnicodeEmojiRule$1;
|
|
.super Lcom/discord/simpleast/core/parser/Rule;
|
|
.source "Rules.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/EnclosingMethod;
|
|
value = Lcom/discord/utilities/textprocessing/Rules;->createUnicodeEmojiRule()Lcom/discord/simpleast/core/parser/Rule;
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
accessFlags = 0x19
|
|
name = null
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"Lcom/discord/simpleast/core/parser/Rule<",
|
|
"TT;",
|
|
"Lcom/discord/simpleast/core/node/Node<",
|
|
"TT;>;TS;>;"
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# instance fields
|
|
.field public final synthetic this$0:Lcom/discord/utilities/textprocessing/Rules;
|
|
|
|
|
|
# direct methods
|
|
.method public constructor <init>(Lcom/discord/utilities/textprocessing/Rules;Ljava/util/regex/Pattern;)V
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/regex/Pattern;",
|
|
")V"
|
|
}
|
|
.end annotation
|
|
|
|
iput-object p1, p0, Lcom/discord/utilities/textprocessing/Rules$createUnicodeEmojiRule$1;->this$0:Lcom/discord/utilities/textprocessing/Rules;
|
|
|
|
invoke-direct {p0, p2}, Lcom/discord/simpleast/core/parser/Rule;-><init>(Ljava/util/regex/Pattern;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public parse(Ljava/util/regex/Matcher;Lcom/discord/simpleast/core/parser/Parser;Ljava/lang/Object;)Lcom/discord/simpleast/core/parser/ParseSpec;
|
|
.locals 4
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/util/regex/Matcher;",
|
|
"Lcom/discord/simpleast/core/parser/Parser<",
|
|
"TT;-",
|
|
"Lcom/discord/simpleast/core/node/Node<",
|
|
"TT;>;TS;>;TS;)",
|
|
"Lcom/discord/simpleast/core/parser/ParseSpec<",
|
|
"TT;TS;>;"
|
|
}
|
|
.end annotation
|
|
|
|
const-string v0, "matcher"
|
|
|
|
invoke-static {p1, v0}, Ly/n/c/j;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string v0, "parser"
|
|
|
|
invoke-static {p2, v0}, Ly/n/c/j;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-virtual {p1}, Ljava/util/regex/Matcher;->group()Ljava/lang/String;
|
|
|
|
move-result-object p1
|
|
|
|
sget-object p2, Lcom/discord/utilities/textprocessing/Rules;->INSTANCE:Lcom/discord/utilities/textprocessing/Rules;
|
|
|
|
invoke-static {p2}, Lcom/discord/utilities/textprocessing/Rules;->access$getEmojiDataProvider$p(Lcom/discord/utilities/textprocessing/Rules;)Lcom/discord/utilities/textprocessing/Rules$EmojiDataProvider;
|
|
|
|
move-result-object p2
|
|
|
|
invoke-interface {p2}, Lcom/discord/utilities/textprocessing/Rules$EmojiDataProvider;->getUnicodeEmojiSurrogateMap()Ljava/util/Map;
|
|
|
|
move-result-object p2
|
|
|
|
invoke-interface {p2, p1}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
move-result-object p2
|
|
|
|
check-cast p2, Lcom/discord/models/domain/emoji/ModelEmojiUnicode;
|
|
|
|
const-string v0, "node"
|
|
|
|
if-eqz p2, :cond_0
|
|
|
|
sget-object p1, Lcom/discord/utilities/textprocessing/node/EmojiNode;->Companion:Lcom/discord/utilities/textprocessing/node/EmojiNode$Companion;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
const/4 v2, 0x2
|
|
|
|
const/4 v3, 0x0
|
|
|
|
invoke-static {p1, p2, v1, v2, v3}, Lcom/discord/utilities/textprocessing/node/EmojiNode$Companion;->from$default(Lcom/discord/utilities/textprocessing/node/EmojiNode$Companion;Lcom/discord/models/domain/emoji/ModelEmojiUnicode;IILjava/lang/Object;)Lcom/discord/utilities/textprocessing/node/EmojiNode;
|
|
|
|
move-result-object p1
|
|
|
|
invoke-static {p1, v0}, Ly/n/c/j;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
new-instance p2, Lcom/discord/simpleast/core/parser/ParseSpec;
|
|
|
|
invoke-direct {p2, p1, p3}, Lcom/discord/simpleast/core/parser/ParseSpec;-><init>(Lcom/discord/simpleast/core/node/Node;Ljava/lang/Object;)V
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
new-instance p2, Lf/a/i/b/a/a;
|
|
|
|
const-string v1, "match"
|
|
|
|
invoke-static {p1, v1}, Ly/n/c/j;->checkNotNullExpressionValue(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-direct {p2, p1}, Lf/a/i/b/a/a;-><init>(Ljava/lang/String;)V
|
|
|
|
invoke-static {p2, v0}, Ly/n/c/j;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
new-instance p1, Lcom/discord/simpleast/core/parser/ParseSpec;
|
|
|
|
invoke-direct {p1, p2, p3}, Lcom/discord/simpleast/core/parser/ParseSpec;-><init>(Lcom/discord/simpleast/core/node/Node;Ljava/lang/Object;)V
|
|
|
|
move-object p2, p1
|
|
|
|
:goto_0
|
|
return-object p2
|
|
.end method
|