Fullscreen Ads - Callbacks

Setting Up a RequestListener and creating an InneractiveFullscreenUnitController

The following example demonstrates how a RequestListener should be used and how to add an event listener properly for receiving Interstitial or Rewarded ad callbacks.

The InneractiveFullScreenAdRewardedListener can be optionally be used to receive rewarded ad callbacks.

Listening for Requests Example
InneractiveAdSpot.RequestListener spotListener = new InneractiveAdSpot.RequestListener() {
            public void onInneractiveFailedAdRequest(InneractiveAdSpot adSpot, InneractiveErrorCode errorCode) {
                Log.i(TAG, "Failed loading fullscreen ad! with error: " + errorCode);
            public void onInneractiveSuccessfulAdRequest(InneractiveAdSpot adSpot) {
                // Register for full screen ad callbacks
                InneractiveFullscreenUnitController controller =
                //Starting with version 7.6.0 of the MarketPlace SDK a rewarded completion listener has also been added - 
                    InneractiveFullscreenUnitController fullscreenUnitController = new InneractiveFullscreenUnitController();
                                    controller.setRewardedListener(new InneractiveFullScreenAdRewardedListener() {
                           public void onAdRewarded(InneractiveAdSpot adSpot) {
                                  Log.i(TAG, "onAdRewarded");
                controller.setEventsListener(new InneractiveFullscreenAdEventsListener() {
                    public void onAdImpression(InneractiveAdSpot adSpot) {
                        Log.i(TAG, "onAdImpression");
                    public void onAdClicked(InneractiveAdSpot adSpot) {
                        Log.i(TAG, "onAdClicked");
                    public void onAdWillCloseInternalBrowser(InneractiveAdSpot adSpot) {
                        Log.i(TAG, "onAdWillCloseInternalBrowser");
Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request