180 lines
3.8 KiB
Smali
180 lines
3.8 KiB
Smali
.class public final Lcom/vk/api/account/AccountSearchContacts$b;
|
|
.super Ljava/lang/Object;
|
|
.source "AccountSearchContacts.kt"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/EnclosingClass;
|
|
value = Lcom/vk/api/account/AccountSearchContacts;
|
|
.end annotation
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
accessFlags = 0x19
|
|
name = "b"
|
|
.end annotation
|
|
|
|
|
|
# direct methods
|
|
.method private constructor <init>()V
|
|
.locals 0
|
|
|
|
.line 1
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public synthetic constructor <init>(Lkotlin/jvm/internal/DefaultConstructorMarker;)V
|
|
.locals 0
|
|
|
|
.line 2
|
|
invoke-direct {p0}, Lcom/vk/api/account/AccountSearchContacts$b;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final a(Ljava/lang/String;Ljava/util/List;Ljava/lang/String;)Lorg/json/JSONObject;
|
|
.locals 5
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Ljava/lang/String;",
|
|
"Ljava/util/List<",
|
|
"Lcom/vk/dto/common/Contact;",
|
|
">;",
|
|
"Ljava/lang/String;",
|
|
")",
|
|
"Lorg/json/JSONObject;"
|
|
}
|
|
.end annotation
|
|
|
|
.line 1
|
|
new-instance v0, Lorg/json/JSONObject;
|
|
|
|
invoke-direct {v0}, Lorg/json/JSONObject;-><init>()V
|
|
|
|
.line 2
|
|
new-instance v1, Lorg/json/JSONArray;
|
|
|
|
invoke-direct {v1}, Lorg/json/JSONArray;-><init>()V
|
|
|
|
.line 3
|
|
invoke-interface {p2}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object p2
|
|
|
|
:goto_0
|
|
invoke-interface {p2}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v2
|
|
|
|
if-eqz v2, :cond_1
|
|
|
|
invoke-interface {p2}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
check-cast v2, Lcom/vk/dto/common/Contact;
|
|
|
|
.line 4
|
|
invoke-virtual {v2}, Lcom/vk/dto/common/Contact;->b()Ljava/util/List;
|
|
|
|
move-result-object v2
|
|
|
|
.line 5
|
|
new-instance v3, Lorg/json/JSONArray;
|
|
|
|
invoke-direct {v3}, Lorg/json/JSONArray;-><init>()V
|
|
|
|
.line 6
|
|
invoke-interface {v2}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
|
|
|
|
move-result-object v2
|
|
|
|
:goto_1
|
|
invoke-interface {v2}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
move-result v4
|
|
|
|
if-eqz v4, :cond_0
|
|
|
|
invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
move-result-object v4
|
|
|
|
check-cast v4, Ljava/lang/String;
|
|
|
|
.line 7
|
|
invoke-virtual {v3, v4}, Lorg/json/JSONArray;->put(Ljava/lang/Object;)Lorg/json/JSONArray;
|
|
|
|
goto :goto_1
|
|
|
|
.line 8
|
|
:cond_0
|
|
invoke-virtual {v1, v3}, Lorg/json/JSONArray;->put(Ljava/lang/Object;)Lorg/json/JSONArray;
|
|
|
|
goto :goto_0
|
|
|
|
.line 9
|
|
:cond_1
|
|
new-instance p2, Lorg/json/JSONObject;
|
|
|
|
invoke-direct {p2}, Lorg/json/JSONObject;-><init>()V
|
|
|
|
const/4 v2, 0x0
|
|
|
|
const/4 v3, 0x1
|
|
|
|
if-eqz p3, :cond_3
|
|
|
|
.line 10
|
|
invoke-interface {p3}, Ljava/lang/CharSequence;->length()I
|
|
|
|
move-result v4
|
|
|
|
if-nez v4, :cond_2
|
|
|
|
goto :goto_2
|
|
|
|
:cond_2
|
|
const/4 v4, 0x0
|
|
|
|
goto :goto_3
|
|
|
|
:cond_3
|
|
:goto_2
|
|
const/4 v4, 0x1
|
|
|
|
:goto_3
|
|
if-nez v4, :cond_4
|
|
|
|
const-string v4, "user_contact"
|
|
|
|
invoke-virtual {p2, v4, p3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;
|
|
|
|
:cond_4
|
|
const-string p3, "contacts"
|
|
|
|
.line 11
|
|
invoke-virtual {p2, p3, v1}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;
|
|
|
|
.line 12
|
|
invoke-interface {p1}, Ljava/lang/CharSequence;->length()I
|
|
|
|
move-result p3
|
|
|
|
if-nez p3, :cond_5
|
|
|
|
const/4 v2, 0x1
|
|
|
|
:cond_5
|
|
if-nez v2, :cond_6
|
|
|
|
invoke-virtual {v0, p1, p2}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;
|
|
|
|
:cond_6
|
|
return-object v0
|
|
.end method
|