.class public Lcom/moji/mjweather/setting/presenter/AccountManageCenterPresenter;
.super Lcom/moji/mjweather/setting/presenter/BaseAccountPreferencePresenter;
.source "AccountManageCenterPresenter.java"


# annotations
.annotation system Ldalvik/annotation/Signature;
    value = {
        "Lcom/moji/mjweather/setting/presenter/BaseAccountPreferencePresenter<",
        "Lcom/moji/mjweather/setting/view/IAccountManageCenterView;",
        ">;"
    }
.end annotation


# direct methods
.method public constructor <init>(Lcom/moji/mjweather/setting/view/IAccountManageCenterView;)V
    .locals 0

    .line 26
    invoke-direct {p0, p1}, Lcom/moji/mjweather/setting/presenter/BaseAccountPreferencePresenter;-><init>(Lcom/moji/mjweather/setting/view/IAccountPreferenceView;)V

    return-void
.end method

.method private final i(Ljava/lang/String;)Ljava/lang/String;
    .locals 1

    .line 52
    new-instance v0, Ljava/lang/StringBuilder;

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

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

    const-string p1, "_moji"

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

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

    move-result-object p1

    invoke-static {p1}, Lcom/moji/tool/EncryptTool;->a(Ljava/lang/String;)Ljava/lang/String;

    move-result-object p1

    return-object p1
.end method

.method private k()I
    .locals 2

    .line 73
    iget-object v0, p0, Lcom/moji/mjweather/setting/presenter/AccountManageCenterPresenter;->a:Lcom/moji/account/data/UserInfoSQLiteManager;

    invoke-static {}, Lcom/moji/account/data/AccountProvider;->a()Lcom/moji/account/data/AccountProvider;

    move-result-object v1

    invoke-virtual {v1}, Lcom/moji/account/data/AccountProvider;->d()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/moji/account/data/UserInfoSQLiteManager;->a(Ljava/lang/String;)Lcom/moji/account/data/UserInfo;

    move-result-object v0

    if-eqz v0, :cond_3

    .line 74
    iget-object v1, v0, Lcom/moji/account/data/UserInfo;->mobile:Ljava/lang/String;

    invoke-static {v1}, Lcom/moji/tool/Utils;->a(Ljava/lang/String;)Z

    move-result v1

    if-nez v1, :cond_0

    iget-object v1, v0, Lcom/moji/account/data/UserInfo;->email:Ljava/lang/String;

    invoke-static {v1}, Lcom/moji/tool/Utils;->a(Ljava/lang/String;)Z

    move-result v1

    if-nez v1, :cond_0

    goto :goto_1

    .line 76
    :cond_0
    iget-object v1, v0, Lcom/moji/account/data/UserInfo;->mobile:Ljava/lang/String;

    invoke-static {v1}, Lcom/moji/tool/Utils;->a(Ljava/lang/String;)Z

    move-result v1

    if-eqz v1, :cond_2

    iget-object v0, v0, Lcom/moji/account/data/UserInfo;->email:Ljava/lang/String;

    invoke-static {v0}, Lcom/moji/skinshop/util/Util;->b(Ljava/lang/String;)Z

    move-result v0

    if-nez v0, :cond_1

    goto :goto_0

    :cond_1
    const/4 v0, 0x1

    return v0

    :cond_2
    :goto_0
    const/4 v0, 0x2

    return v0

    :cond_3
    :goto_1
    const/4 v0, 0x3

    return v0
.end method


# virtual methods
.method public a(Ljava/lang/String;)Z
    .locals 1

    .line 43
    invoke-static {p1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    if-eqz v0, :cond_0

    const/4 p1, 0x1

    return p1

    :cond_0
    const-string v0, "moji"

    .line 47
    invoke-direct {p0, v0}, Lcom/moji/mjweather/setting/presenter/AccountManageCenterPresenter;->i(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

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

    move-result p1

    return p1
.end method

.method public d()V
    .locals 2

    .line 33
    invoke-direct {p0}, Lcom/moji/mjweather/setting/presenter/AccountManageCenterPresenter;->k()I

    move-result v0

    .line 34
    iget-object v1, p0, Lcom/moji/mjweather/setting/presenter/AccountManageCenterPresenter;->f:Lcom/moji/mvpframe/IMJMvpView;

    check-cast v1, Lcom/moji/mjweather/setting/view/IAccountManageCenterView;

    invoke-interface {v1, v0}, Lcom/moji/mjweather/setting/view/IAccountManageCenterView;->a(I)V

    return-void
.end method
