GoogleInteractiveMediaAds Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
IMAAdsLoaderDelegate
@protocol IMAAdsLoaderDelegate
Delegate object that receives state change callbacks from IMAAdsLoader.
-
Called when ads are successfully loaded from the ad servers by the loader.
Parameters
loader
|
the IMAAdsLoader that received the loaded ad data
|
adsLoadedData
|
the IMAAdsLoadedData instance containing ad data
|
-
Error reported by the ads loader when loading or requesting an ad fails.
Parameters
loader
|
the IMAAdsLoader that received the error
|
adErrorData
|
the IMAAdLoadingErrorData instance with error information
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-20 UTC.
[null,null,["Last updated 2025-08-20 UTC."],[[["\u003cp\u003eThe \u003ccode\u003eIMAAdsLoaderDelegate\u003c/code\u003e protocol defines methods to handle ad loading events in Google Interactive Media Ads (IMA).\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eadsLoader:adsLoadedWithData:\u003c/code\u003e is called when ads are successfully loaded, providing access to the ad data through \u003ccode\u003eIMAAdsLoadedData\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eadsLoader:failedWithErrorData:\u003c/code\u003e is called when ad loading fails, providing error information through \u003ccode\u003eIMAAdLoadingErrorData\u003c/code\u003e.\u003c/p\u003e\n"]]],[],null,["# GoogleInteractiveMediaAds Framework Reference\n\nIMAAdsLoaderDelegate\n====================\n\n @protocol IMAAdsLoaderDelegate\n\nDelegate object that receives state change callbacks from IMAAdsLoader.\n- `\n ``\n ``\n `\n\n ### [-adsLoader:adsLoadedWithData:](#/c:objc(pl)IMAAdsLoaderDelegate(im)adsLoader:adsLoadedWithData:)\n\n `\n ` \n Called when ads are successfully loaded from the ad servers by the loader. \n\n #### Declaration\n\n Swift \n\n func adsLoader(_ loader: ../Classes/IMAAdsLoader.html, adsLoadedWith adsLoadedData: ../Classes/IMAAdsLoadedData.html)\n\n Objective-C \n\n - (void)adsLoader:(nonnull ../Classes/IMAAdsLoader.html *)loader\n adsLoadedWithData:(nonnull ../Classes/IMAAdsLoadedData.html *)adsLoadedData;\n\n #### Parameters\n\n |-----------------------|---------------------------------------------------|\n | ` `*loader*` ` | the IMAAdsLoader that received the loaded ad data |\n | ` `*adsLoadedData*` ` | the IMAAdsLoadedData instance containing ad data |\n\n- `\n ``\n ``\n `\n\n ### [-adsLoader:failedWithErrorData:](#/c:objc(pl)IMAAdsLoaderDelegate(im)adsLoader:failedWithErrorData:)\n\n `\n ` \n Error reported by the ads loader when loading or requesting an ad fails. \n\n #### Declaration\n\n Swift \n\n func adsLoader(_ loader: ../Classes/IMAAdsLoader.html, failedWith adErrorData: ../Classes/IMAAdLoadingErrorData.html)\n\n Objective-C \n\n - (void)adsLoader:(nonnull ../Classes/IMAAdsLoader.html *)loader\n failedWithErrorData:(nonnull ../Classes/IMAAdLoadingErrorData.html *)adErrorData;\n\n #### Parameters\n\n |---------------------|-----------------------------------------------------------|\n | ` `*loader*` ` | the IMAAdsLoader that received the error |\n | ` `*adErrorData*` ` | the IMAAdLoadingErrorData instance with error information |"]]