Skip to content

Instantly share code, notes, and snippets.

@ydn
Created June 10, 2015 22:24
Show Gist options
  • Save ydn/d97cd8873afddf6464fa to your computer and use it in GitHub Desktop.
Save ydn/d97cd8873afddf6464fa to your computer and use it in GitHub Desktop.
Flurry Full-Screen Ad Integration callbacks (Swift)
class ViewController: UIViewController, FlurryAdInterstitialDelegate {
func adInterstitialDidFetchAd(interstitialAd: FlurryAdInterstitial!) {
// You can choose to present the ad as soon as it is received
interstitialAd.presentWithViewController(self);
}
// Invoked when the interstitial ad is rendered
func adInterstitialDidRender(interstitialAd: FlurryAdInterstitial!) {
}
// Informs the app that a video associated with this ad has finished playing
// Only present for rewarded & client-side rewarded ad spaces
func adInterstitialVideoDidFinish(interstitialAd: FlurryAdInterstitial!) {
}
// Informational callback invoked when there is an ad error
func adInterstitial(interstitialAd: FlurryAdInterstitial!, adError: FlurryAdError, errorDescription: NSError!) {
// @param interstitialAd The interstitial ad object associated with the error
// @param adError an enum that gives the reason for the error
// @param errorDescription An error object that gives additional information on the cause of the ad error
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment