DataPointUtils.smali
.class public Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;
.super Ljava/lang/Object;
# static fields
.field private static b:Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;
# instance fields
.field private a:Landroid/content/Context;
.field private c:Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;
# direct methods
.method public constructor <init>(Landroid/content/Context;)V
.registers 2
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
iput-object p1, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->a:Landroid/content/Context;
return-void
.end method
.method public static getInstance(Landroid/content/Context;)Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;
.registers 2
sget-object v0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->b:Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;
if-nez v0, :cond_b
new-instance v0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;
invoke-direct {v0, p0}, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;-><init>(Landroid/content/Context;)V
sput-object v0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->b:Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;
:cond_b
sget-object p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->b:Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;
return-object p0
.end method
# virtual methods
.method public loadConfigStart(ZLjava/lang/String;)V
.registers 5
invoke-static {}, Lcom/tradplus/ads/pushcenter/utils/SendMessageUtil;->getInstance()Lcom/tradplus/ads/pushcenter/utils/SendMessageUtil;
move-result-object v0
iget-object v1, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->a:Landroid/content/Context;
invoke-virtual {v0, v1, p2, p1}, Lcom/tradplus/ads/pushcenter/utils/SendMessageUtil;->sendLoadAdconfStart(Landroid/content/Context;Ljava/lang/String;Z)V
return-void
.end method
.method public openEnd(Ljava/lang/String;)V
.registers 7
iget-object v0, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->c:Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;
new-instance v1, Ljava/lang/StringBuilder;
invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V
invoke-static {}, Lcom/tradplus/ads/pushcenter/utils/RequestUtils;->getInstance()Lcom/tradplus/ads/pushcenter/utils/RequestUtils;
move-result-object v2
iget-object v3, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->c:Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;
invoke-virtual {v3}, Lcom/tradplus/ads/pushcenter/reqeust/BaseRequest;->getCreateTime()J
move-result-wide v3
invoke-virtual {v2, v3, v4}, Lcom/tradplus/ads/pushcenter/utils/RequestUtils;->countRuntime(J)J
move-result-wide v2
invoke-virtual {v1, v2, v3}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
const-string 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-virtual {v0, v1}, Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;->setRt(Ljava/lang/String;)V
iget-object v0, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->c:Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;
invoke-virtual {v0, p1}, Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;->setEc(Ljava/lang/String;)V
invoke-static {}, Lcom/tradplus/ads/pushcenter/PushCenter;->getInstance()Lcom/tradplus/ads/pushcenter/PushCenter;
move-result-object p1
iget-object v0, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->a:Landroid/content/Context;
iget-object v1, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->c:Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;
sget v2, Lcom/tradplus/ads/mobileads/util/TradPlusDataConstants;->CACHETRADPLUSTYPE:I
invoke-virtual {p1, v0, v1, v2}, Lcom/tradplus/ads/pushcenter/PushCenter;->sendMessageToCenter(Landroid/content/Context;Ljava/lang/Object;I)V
return-void
.end method
.method public openStart()V
.registers 4
invoke-static {}, Lcom/tradplus/ads/pushcenter/utils/SendMessageUtil;->getInstance()Lcom/tradplus/ads/pushcenter/utils/SendMessageUtil;
move-result-object v0
iget-object v1, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->a:Landroid/content/Context;
invoke-virtual {v0, v1}, Lcom/tradplus/ads/pushcenter/utils/SendMessageUtil;->sendOpenAPIStart(Landroid/content/Context;)V
new-instance v0, Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;
iget-object v1, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->a:Landroid/content/Context;
sget-object v2, Lcom/tradplus/ads/pushcenter/utils/PushMessageUtils$PushStatus;->EV_REQ_OPEN_API:Lcom/tradplus/ads/pushcenter/utils/PushMessageUtils$PushStatus;
invoke-virtual {v2}, Lcom/tradplus/ads/pushcenter/utils/PushMessageUtils$PushStatus;->getValue()Ljava/lang/String;
move-result-object v2
invoke-direct {v0, v1, v2}, Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;-><init>(Landroid/content/Context;Ljava/lang/String;)V
iput-object v0, p0, Lcom/tradplus/ads/pushcenter/utils/DataPointUtils;->c:Lcom/tradplus/ads/pushcenter/reqeust/OpenRequest;
return-void
.end method