VipDataManager.smali
.class public Lcom/sandboxol/center/utils/VipDataManager;
.super Ljava/lang/Object;
.source "VipDataManager.java"
# static fields
.field private static vipDataManager:Lcom/sandboxol/center/utils/VipDataManager;
# instance fields
.field private garenaSubIds:Ljava/util/List;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/List<",
"Ljava/lang/String;",
">;"
}
.end annotation
.end field
.field private vipProductResponse:Lcom/sandboxol/center/router/moduleInfo/pay/VipProductResponse;
.field private vipSubInfo:Lcom/sandboxol/center/entity/VipSubInfo;
# direct methods
.method private constructor <init>()V
.registers 2
.line 1
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
.line 2
new-instance v0, Ljava/util/ArrayList;
invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V
iput-object v0, p0, Lcom/sandboxol/center/utils/VipDataManager;->garenaSubIds:Ljava/util/List;
return-void
.end method
.method public static getInstance()Lcom/sandboxol/center/utils/VipDataManager;
.registers 1
.line 1
sget-object v0, Lcom/sandboxol/center/utils/VipDataManager;->vipDataManager:Lcom/sandboxol/center/utils/VipDataManager;
if-nez v0, :cond_b
.line 2
new-instance v0, Lcom/sandboxol/center/utils/VipDataManager;
invoke-direct {v0}, Lcom/sandboxol/center/utils/VipDataManager;-><init>()V
sput-object v0, Lcom/sandboxol/center/utils/VipDataManager;->vipDataManager:Lcom/sandboxol/center/utils/VipDataManager;
.line 3
:cond_b
sget-object v0, Lcom/sandboxol/center/utils/VipDataManager;->vipDataManager:Lcom/sandboxol/center/utils/VipDataManager;
return-object v0
.end method
# virtual methods
.method public getVipProductResponse()Lcom/sandboxol/center/router/moduleInfo/pay/VipProductResponse;
.registers 2
.line 1
iget-object v0, p0, Lcom/sandboxol/center/utils/VipDataManager;->vipProductResponse:Lcom/sandboxol/center/router/moduleInfo/pay/VipProductResponse;
return-object v0
.end method
.method public getVipSubInfo()Lcom/sandboxol/center/entity/VipSubInfo;
.registers 2
.line 1
iget-object v0, p0, Lcom/sandboxol/center/utils/VipDataManager;->vipSubInfo:Lcom/sandboxol/center/entity/VipSubInfo;
return-object v0
.end method
.method public isSubGGProduct(Ljava/lang/String;)Z
.registers 3
.line 1
iget-object v0, p0, Lcom/sandboxol/center/utils/VipDataManager;->garenaSubIds:Ljava/util/List;
invoke-interface {v0, p1}, Ljava/util/List;->contains(Ljava/lang/Object;)Z
move-result p1
return p1
.end method
.method public setVipProductResponse(Lcom/sandboxol/center/router/moduleInfo/pay/VipProductResponse;)V
.registers 7
.line 1
iput-object p1, p0, Lcom/sandboxol/center/utils/VipDataManager;->vipProductResponse:Lcom/sandboxol/center/router/moduleInfo/pay/VipProductResponse;
.line 2
invoke-virtual {p1}, Lcom/sandboxol/center/router/moduleInfo/pay/VipProductResponse;->getProducts()Ljava/util/Map;
move-result-object v0
invoke-interface {v0}, Ljava/util/Map;->keySet()Ljava/util/Set;
move-result-object v0
invoke-interface {v0}, Ljava/util/Set;->iterator()Ljava/util/Iterator;
move-result-object v0
:cond_e
invoke-interface {v0}, Ljava/util/Iterator;->hasNext()Z
move-result v1
if-eqz v1, :cond_6c
invoke-interface {v0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v1
check-cast v1, Ljava/lang/String;
.line 3
invoke-virtual {p1}, Lcom/sandboxol/center/router/moduleInfo/pay/VipProductResponse;->getProducts()Ljava/util/Map;
move-result-object v2
invoke-interface {v2, v1}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
move-result-object v2
if-eqz v2, :cond_e
.line 4
invoke-virtual {p1}, Lcom/sandboxol/center/router/moduleInfo/pay/VipProductResponse;->getProducts()Ljava/util/Map;
move-result-object v2
invoke-interface {v2, v1}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
move-result-object v2
check-cast v2, Ljava/util/List;
invoke-interface {v2}, Ljava/util/List;->size()I
move-result v2
if-lez v2, :cond_e
.line 5
invoke-virtual {p1}, Lcom/sandboxol/center/router/moduleInfo/pay/VipProductResponse;->getProducts()Ljava/util/Map;
move-result-object v2
invoke-interface {v2, v1}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
move-result-object v1
check-cast v1, Ljava/util/List;
invoke-interface {v1}, Ljava/util/List;->iterator()Ljava/util/Iterator;
move-result-object v1
:cond_42
:goto_42
invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z
move-result v2
if-eqz v2, :cond_e
invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v2
check-cast v2, Lcom/sandboxol/center/router/moduleInfo/pay/VipProductEntity;
if-eqz v2, :cond_42
.line 6
invoke-virtual {v2}, Lcom/sandboxol/center/router/moduleInfo/pay/VipProductEntity;->getType()Ljava/lang/String;
move-result-object v3
if-eqz v3, :cond_42
invoke-virtual {v2}, Lcom/sandboxol/center/router/moduleInfo/pay/VipProductEntity;->getType()Ljava/lang/String;
move-result-object v3
const-string v4, "sub"
invoke-virtual {v3, v4}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z
move-result v3
if-eqz v3, :cond_42
.line 7
iget-object v3, p0, Lcom/sandboxol/center/utils/VipDataManager;->garenaSubIds:Ljava/util/List;
invoke-virtual {v2}, Lcom/sandboxol/center/router/moduleInfo/pay/VipProductEntity;->getGarenaProductId()Ljava/lang/String;
move-result-object v2
invoke-interface {v3, v2}, Ljava/util/List;->add(Ljava/lang/Object;)Z
goto :goto_42
:cond_6c
return-void
.end method
.method public setVipSubInfo(Lcom/sandboxol/center/entity/VipSubInfo;)V
.registers 2
.line 1
iput-object p1, p0, Lcom/sandboxol/center/utils/VipDataManager;->vipSubInfo:Lcom/sandboxol/center/entity/VipSubInfo;
return-void
.end method