FlutterQqAds class

腾讯广告 Flutter 插件

Constructors

FlutterQqAds()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

platformVersion Future<String>
no setter
requestIDFA Future<bool>
请求应用跟踪透明度授权
no setter

Static Methods

clearFeedAd(List<int> list) Future<bool>
清除信息流广告列表 list 信息流广告 id 列表
initAd(String appId) Future<bool>
初始化广告 appId 应用媒体ID
loadFeedAd(String posId, {int width = 375, int height = 0, int count = 1}) Future<List<int>>
加载信息流广告列表 posId 广告位 id width 宽度 height 高度,0:代表自适应广告高度 count 获取广告数量,建议 1~3 个
onEventListener(OnAdEventListener onAdEventListener) Future<void>
事件回调 @params onData 事件回调
setPersonalizedState(int state) Future<bool>
设置个性化广告 0:代表开启个性化广告推荐,1:代表关闭个性化广告推荐
showInterstitialAd(String posId, {bool showPopup = false, bool showFullScreenVideo = false, bool showRewardVideo = false, bool autoPlayOnWifi = false, bool autoPlayMuted = true, bool detailPageMuted = false, String? customData, String? userId}) Future<bool>
展示插屏广告 posId 广告位 id showPopup Popup 形式显示(仅 Android) showFullScreenVideo 插屏全屏视频形式显示 showRewardVideo 插屏激励视频形式显示 autoPlayOnWifi 是否仅在 WiFi 网络下自动播放 autoPlayMuted 自动播放是否静音 detailPageMuted 详情页是否静音 customData 设置服务端验证的自定义信息 userId 设置服务端验证的用户信息
showRewardVideoAd(String posId, {bool playMuted = false, String? customData, String? userId}) Future<bool>
展示激励视频广告 posId 广告位 id playMuted 是否静音播放 customData 设置服务端验证的自定义信息 userId 设置服务端验证的用户信息
showSplashAd(String posId, {double fetchDelay = 3}) Future<bool>
展示开屏广告 posId 广告位 id logo 如果传值则展示底部logo,不传不展示,则全屏展示 fetchDelay 拉取广告的超时时间,默认值 3 秒,取值范围1.5~5