PushConfigManager$3$1.smali

.class Lio/rong/push/pushconfig/PushConfigManager$3$1;
.super Ljava/lang/Object;
.source "PushConfigManager.java"

# interfaces
.implements Lio/rong/push/core/PushClient$QueryCallback;


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Lio/rong/push/pushconfig/PushConfigManager$3;->run()V
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic this$1:Lio/rong/push/pushconfig/PushConfigManager$3;


# direct methods
.method constructor <init>(Lio/rong/push/pushconfig/PushConfigManager$3;)V
    .registers 2

    .line 1
    iput-object p1, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public onFailure(Lio/rong/push/PushErrorCode;)V
    .registers 3

    .line 1
    # getter for: Lio/rong/push/pushconfig/PushConfigManager;->pushClient:Lio/rong/push/core/PushClient;
    invoke-static {}, Lio/rong/push/pushconfig/PushConfigManager;->access$100()Lio/rong/push/core/PushClient;

    move-result-object v0

    invoke-virtual {v0}, Lio/rong/push/core/PushClient;->disconnect()V

    .line 2
    iget-object v0, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object v0, v0, Lio/rong/push/pushconfig/PushConfigManager$3;->this$0:Lio/rong/push/pushconfig/PushConfigManager;

    # getter for: Lio/rong/push/pushconfig/PushConfigManager;->configResultCallback:Lio/rong/push/pushconfig/IPushConfigObserver;
    invoke-static {v0}, Lio/rong/push/pushconfig/PushConfigManager;->access$400(Lio/rong/push/pushconfig/PushConfigManager;)Lio/rong/push/pushconfig/IPushConfigObserver;

    move-result-object v0

    invoke-interface {v0, p1}, Lio/rong/push/pushconfig/IPushConfigObserver;->onError(Lio/rong/push/PushErrorCode;)V

    .line 3
    iget-object p1, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object p1, p1, Lio/rong/push/pushconfig/PushConfigManager$3;->this$0:Lio/rong/push/pushconfig/PushConfigManager;

    # getter for: Lio/rong/push/pushconfig/PushConfigManager;->TAG:Ljava/lang/String;
    invoke-static {p1}, Lio/rong/push/pushconfig/PushConfigManager;->access$300(Lio/rong/push/pushconfig/PushConfigManager;)Ljava/lang/String;

    move-result-object p1

    const-string v0, "Failure when query!"

    invoke-static {p1, v0}, Lio/rong/push/common/RLog;->e(Ljava/lang/String;Ljava/lang/String;)V

    return-void
.end method

.method public onSuccess(Ljava/lang/String;)V
    .registers 5

    .line 1
    iget-object v0, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object v0, v0, Lio/rong/push/pushconfig/PushConfigManager$3;->this$0:Lio/rong/push/pushconfig/PushConfigManager;

    # getter for: Lio/rong/push/pushconfig/PushConfigManager;->TAG:Ljava/lang/String;
    invoke-static {v0}, Lio/rong/push/pushconfig/PushConfigManager;->access$300(Lio/rong/push/pushconfig/PushConfigManager;)Ljava/lang/String;

    move-result-object v0

    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    const-string v2, "query result:"

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string v2, ";prefer type:"

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    iget-object v2, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object v2, v2, Lio/rong/push/pushconfig/PushConfigManager$3;->val$preferPushType:Lio/rong/push/PushType;

    invoke-virtual {v2}, Lio/rong/push/PushType;->getName()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-static {v0, v1}, Lio/rong/push/common/RLog;->d(Ljava/lang/String;Ljava/lang/String;)V

    .line 2
    iget-object v0, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object v0, v0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$preferPushType:Lio/rong/push/PushType;

    invoke-virtual {v0}, Lio/rong/push/PushType;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {p1, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-nez v0, :cond_7d

    sget-object v0, Lio/rong/push/PushType;->GOOGLE_GCM:Lio/rong/push/PushType;

    .line 3
    invoke-virtual {v0}, Lio/rong/push/PushType;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {p1, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-nez v0, :cond_7d

    sget-object v0, Lio/rong/push/PushType;->GOOGLE_FCM:Lio/rong/push/PushType;

    .line 4
    invoke-virtual {v0}, Lio/rong/push/PushType;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {p1, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-nez v0, :cond_7d

    iget-object v0, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object v0, v0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$preferPushType:Lio/rong/push/PushType;

    sget-object v1, Lio/rong/push/PushType;->UNKNOWN:Lio/rong/push/PushType;

    .line 5
    invoke-virtual {v0, v1}, Ljava/lang/Enum;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_6b

    sget-object v0, Lio/rong/push/PushType;->RONG:Lio/rong/push/PushType;

    invoke-virtual {v0}, Lio/rong/push/PushType;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {p1, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_6b

    goto :goto_7d

    .line 6
    :cond_6b
    iget-object p1, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object p1, p1, Lio/rong/push/pushconfig/PushConfigManager$3;->this$0:Lio/rong/push/pushconfig/PushConfigManager;

    # getter for: Lio/rong/push/pushconfig/PushConfigManager;->configResultCallback:Lio/rong/push/pushconfig/IPushConfigObserver;
    invoke-static {p1}, Lio/rong/push/pushconfig/PushConfigManager;->access$400(Lio/rong/push/pushconfig/PushConfigManager;)Lio/rong/push/pushconfig/IPushConfigObserver;

    move-result-object p1

    iget-object v0, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object v0, v0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$preferPushType:Lio/rong/push/PushType;

    sget-object v1, Lio/rong/push/PushErrorCode;->NOT_REGISTER_IN_ADMIN:Lio/rong/push/PushErrorCode;

    invoke-interface {p1, v0, v1}, Lio/rong/push/pushconfig/IPushConfigObserver;->onFail(Lio/rong/push/PushType;Lio/rong/push/PushErrorCode;)V

    goto :goto_a6

    .line 7
    :cond_7d
    :goto_7d
    sget-object v0, Lio/rong/push/PushType;->RONG:Lio/rong/push/PushType;

    invoke-virtual {v0}, Lio/rong/push/PushType;->getName()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {p1, v0}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v0

    if-eqz v0, :cond_97

    .line 8
    iget-object p1, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object p1, p1, Lio/rong/push/pushconfig/PushConfigManager$3;->this$0:Lio/rong/push/pushconfig/PushConfigManager;

    # getter for: Lio/rong/push/pushconfig/PushConfigManager;->configResultCallback:Lio/rong/push/pushconfig/IPushConfigObserver;
    invoke-static {p1}, Lio/rong/push/pushconfig/PushConfigManager;->access$400(Lio/rong/push/pushconfig/PushConfigManager;)Lio/rong/push/pushconfig/IPushConfigObserver;

    move-result-object p1

    sget-object v0, Lio/rong/push/PushType;->RONG:Lio/rong/push/PushType;

    invoke-interface {p1, v0}, Lio/rong/push/pushconfig/IPushConfigObserver;->onSuccess(Lio/rong/push/PushType;)V

    goto :goto_a6

    .line 9
    :cond_97
    iget-object v0, p0, Lio/rong/push/pushconfig/PushConfigManager$3$1;->this$1:Lio/rong/push/pushconfig/PushConfigManager$3;

    iget-object v0, v0, Lio/rong/push/pushconfig/PushConfigManager$3;->this$0:Lio/rong/push/pushconfig/PushConfigManager;

    # getter for: Lio/rong/push/pushconfig/PushConfigManager;->configResultCallback:Lio/rong/push/pushconfig/IPushConfigObserver;
    invoke-static {v0}, Lio/rong/push/pushconfig/PushConfigManager;->access$400(Lio/rong/push/pushconfig/PushConfigManager;)Lio/rong/push/pushconfig/IPushConfigObserver;

    move-result-object v0

    invoke-static {p1}, Lio/rong/push/PushType;->getType(Ljava/lang/String;)Lio/rong/push/PushType;

    move-result-object p1

    invoke-interface {v0, p1}, Lio/rong/push/pushconfig/IPushConfigObserver;->onGetPushType(Lio/rong/push/PushType;)V

    :goto_a6
    return-void
.end method