AdsManager.smali
.class public Lcom/sandboxol/center/router/manager/AdsManager;
.super Ljava/lang/Object;
.source "AdsManager.java"
# static fields
.field public static final MAIN_CAN_VIEW_ADS_COUNT:I = 0x2
.field private static iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
# direct methods
.method static constructor <clinit>()V
.registers 1
const-string v0, "/ads/service"
.line 1
invoke-static {v0}, Lcom/sandboxol/center/router/RouteServiceManager;->provide(Ljava/lang/String;)Lcom/alibaba/android/arouter/facade/template/IProvider;
move-result-object v0
check-cast v0, Lcom/sandboxol/center/router/moduleApi/IAdsService;
sput-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
return-void
.end method
.method public constructor <init>()V
.registers 1
.line 1
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
return-void
.end method
.method public static clickToShowVideo(Landroid/content/Context;I)V
.registers 3
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_7
.line 2
invoke-interface {v0, p0, p1}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->clickToShowVideo(Landroid/content/Context;I)V
:cond_7
return-void
.end method
.method public static getAdsInfo()Lcom/sandboxol/center/router/moduleInfo/ads/AdsInfo;
.registers 1
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_9
.line 2
invoke-interface {v0}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->getAdsInfo()Lcom/sandboxol/center/router/moduleInfo/ads/AdsInfo;
move-result-object v0
return-object v0
.line 3
:cond_9
new-instance v0, Lcom/sandboxol/center/router/moduleInfo/ads/AdsInfo;
invoke-direct {v0}, Lcom/sandboxol/center/router/moduleInfo/ads/AdsInfo;-><init>()V
return-object v0
.end method
.method public static init(Landroid/app/Activity;)V
.registers 2
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_7
.line 2
invoke-interface {v0, p0}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->init(Landroid/app/Activity;)V
:cond_7
return-void
.end method
.method public static isShowIronAds(Landroid/content/Context;II)Z
.registers 4
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_9
.line 2
invoke-interface {v0, p0, p1, p2}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->isShowIronAds(Landroid/content/Context;II)Z
move-result p0
return p0
:cond_9
const/4 p0, 0x0
return p0
.end method
.method public static isVideoLoaded()Z
.registers 1
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_9
.line 2
invoke-interface {v0}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->isVideoLoaded()Z
move-result v0
return v0
:cond_9
const/4 v0, 0x0
return v0
.end method
.method public static onPause(Landroid/app/Activity;)V
.registers 2
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_7
.line 2
invoke-interface {v0, p0}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->onPause(Landroid/app/Activity;)V
:cond_7
return-void
.end method
.method public static onResume(Landroid/app/Activity;)V
.registers 2
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_7
.line 2
invoke-interface {v0, p0}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->onResume(Landroid/app/Activity;)V
:cond_7
return-void
.end method
.method public static setRewardedVideoListener(Landroid/app/Activity;Lcom/sandboxol/common/interfaces/RewardVideoAdapter;)V
.registers 3
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_7
.line 2
invoke-interface {v0, p0, p1}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->setRewardedVideoListener(Landroid/app/Activity;Lcom/sandboxol/common/interfaces/RewardVideoAdapter;)V
:cond_7
return-void
.end method
.method public static showRewardVideo(I)V
.registers 2
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_7
.line 2
invoke-interface {v0, p0}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->showRewardVideo(I)V
:cond_7
return-void
.end method
.method public static showRewardVideo(IJ)V
.registers 4
.line 5
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_7
.line 6
invoke-interface {v0, p0, p1, p2}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->showRewardVideo(IJ)V
:cond_7
return-void
.end method
.method public static showRewardVideo(ILjava/lang/String;)V
.registers 3
.line 3
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_7
.line 4
invoke-interface {v0, p0, p1}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->showRewardVideo(ILjava/lang/String;)V
:cond_7
return-void
.end method
.method public static showRewardVideoByPlacement(Landroid/app/Activity;ILjava/lang/String;Ljava/lang/String;)V
.registers 5
.line 1
sget-object v0, Lcom/sandboxol/center/router/manager/AdsManager;->iAdsService:Lcom/sandboxol/center/router/moduleApi/IAdsService;
if-eqz v0, :cond_7
.line 2
invoke-interface {v0, p0, p1, p2, p3}, Lcom/sandboxol/center/router/moduleApi/IAdsService;->showRewardVideoByPlacement(Landroid/app/Activity;ILjava/lang/String;Ljava/lang/String;)V
:cond_7
return-void
.end method