Amazon_iOS_Banner_AutoRefresh - imobile/app-mediation GitHub Wiki
※以下の文書はAmazon Publisher ServicesのドキュメントをAmazonの許諾を得て転載したものです。
Auto Refresh of Ads
The ads can be auto-refreshed by setting the following property on DTBAdLoader. The default value is 60 seconds:
[adLoader setAutoRefresh]
If you want to use custom durations for auto refresh, provide value in seconds (say 45 seconds) as follows. The minimum auto refresh time supported is 20 seconds. Anything lower than 20 seconds will fall back to our default 60 seconds:
[adLoader setAutoRefresh:45]
Don’t forget to stop auto refresh. Recommended places for stopping auto refresh are viewDidUnload and viewDidDisappear. Please note that improper handling of auto refresh may result in impression discrepancies.
[adLoader stop]
Note:
- It is important to stop auto refresh of ads and clean up resources of DTB Ad loader. Auto refresh of ads will continue if it is not stopped explicitly and can cause unwanted behaviors and lower impression counts.
- Set property of auto refresh before loadAd call. A single instance of DTBAdLoader can be used only for one loadAd call, and cannot be reused once stop() is called.
- You should avoid initiating new adViews in onSuccess and onFailure callback. This may result in memory leak since the views are stacked on top of each other. You can consider clearing the views before adding new views.
- It’s recommended to disable auto refresh of ads provided by your ad server to avoid conflicts with DTB auto-refresh.