PushConfigManager$3.smali

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

# interfaces
.implements Ljava/lang/Runnable;


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Lio/rong/push/pushconfig/PushConfigManager;->queryPushType(Landroid/content/Context;Ljava/lang/String;Ljava/lang/String;Lio/rong/push/PushType;)V
.end annotation

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


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

.field final synthetic val$appKey:Ljava/lang/String;

.field final synthetic val$context:Landroid/content/Context;

.field final synthetic val$enabledPushTypes:Ljava/lang/String;

.field final synthetic val$preferPushType:Lio/rong/push/PushType;


# direct methods
.method constructor <init>(Lio/rong/push/pushconfig/PushConfigManager;Landroid/content/Context;Ljava/lang/String;Ljava/lang/String;Lio/rong/push/PushType;)V
    .registers 6

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

    iput-object p2, p0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$context:Landroid/content/Context;

    iput-object p3, p0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$appKey:Ljava/lang/String;

    iput-object p4, p0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$enabledPushTypes:Ljava/lang/String;

    iput-object p5, p0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$preferPushType:Lio/rong/push/PushType;

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

    return-void
.end method


# virtual methods
.method public run()V
    .registers 7

    .line 1
    iget-object v0, p0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$context:Landroid/content/Context;

    invoke-virtual {v0}, Landroid/content/Context;->getPackageName()Ljava/lang/String;

    move-result-object v0

    const-string v1, "-"

    const-string v2, "_"

    invoke-virtual {v0, v1, v2}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object v0

    .line 2
    iget-object v1, p0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$context:Landroid/content/Context;

    iget-object v2, p0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$appKey:Ljava/lang/String;

    invoke-static {v1, v2}, Lio/rong/imlib/common/DeviceUtils;->getDeviceId(Landroid/content/Context;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    .line 3
    invoke-static {}, Lio/rong/imlib/common/DeviceUtils;->getDeviceManufacturer()Ljava/lang/String;

    move-result-object v2

    const/4 v3, 0x4

    .line 4
    new-array v3, v3, [Ljava/lang/Object;

    iget-object v4, p0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$enabledPushTypes:Ljava/lang/String;

    const/4 v5, 0x0

    aput-object v4, v3, v5

    iget-object v4, p0, Lio/rong/push/pushconfig/PushConfigManager$3;->val$appKey:Ljava/lang/String;

    const/4 v5, 0x1

    aput-object v4, v3, v5

    const/4 v4, 0x2

    aput-object v0, v3, v4

    const/4 v0, 0x3

    aput-object v2, v3, v0

    const-string v0, "%s-%s-%s-%s"

    invoke-static {v0, v3}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v0

    .line 5
    # 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 v2

    sget-object v3, Lio/rong/push/core/PushClient$QueryMethod;->GET_PUSH_TYPE:Lio/rong/push/core/PushClient$QueryMethod;

    new-instance v4, Lio/rong/push/pushconfig/PushConfigManager$3$1;

    invoke-direct {v4, p0}, Lio/rong/push/pushconfig/PushConfigManager$3$1;-><init>(Lio/rong/push/pushconfig/PushConfigManager$3;)V

    invoke-virtual {v2, v3, v0, v1, v4}, Lio/rong/push/core/PushClient;->query(Lio/rong/push/core/PushClient$QueryMethod;Ljava/lang/String;Ljava/lang/String;Lio/rong/push/core/PushClient$QueryCallback;)V

    return-void
.end method