performShow method
Implementation
@override
Future<void> performShow(RewardedAd ad, {AdOptions? options, AdCallBack? adCallBack}) async {
if (options != null) {
await ad.setServerSideOptions(options.serverSideVerificationOptions);
}
bool isEarnedReward = false;
ad.onPaidEvent = notifyAdRevenue;
ad.fullScreenContentCallback = getCallback(
adCallBack,
onAdDismissedFullScreenContent: (ad) {
ad.dispose();
adCallBack?.onAdDismissed?.call(adsType, isEarnedReward: isEarnedReward);
},
);
ad.show(onUserEarnedReward: (ad, reward) {
adCallBack?.onRewardEarned?.call(adsType);
isEarnedReward = true;
LogUtils.i('$adsType: User earned reward: ${reward.amount} ${reward.type}');
});
}