GoogleMobileAds Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
GADMAdNetworkConnector
Ad network adapters interact with the mediation SDK using an object that implements the
GADMAdNetworkConnector protocol. The connector object can be used to obtain necessary
information for ad requests, and to call back to the mediation SDK on ad request returns and
user interactions.
-
When you need to show a landing page or any other modal view, such as when a user clicks or when
your Ads SDK needs to show an interstitial, use this method to obtain a UIViewController that
you can use to show your modal view. Call the -presentViewController:animated:completion: method
of the returned UIViewController.
Declaration
Swift
func viewControllerForPresentingModalView() -> UIViewController!
Objective-C
- (UIViewController *)viewControllerForPresentingModalView;
-
Returns the preferred ad volume as a fraction of system volume (0.0 to 1.0).
Declaration
Swift
func adVolume() -> Float
Objective-C
- (float)adVolume;
-
Returns whether the ad should be muted.
Declaration
Swift
func adMuted() -> Bool
Objective-C
- (BOOL)adMuted;
-
Tells the connector that the adapter failed to receive an ad.
-
Tells the connector that the adapter received a banner ad.
-
Tells the connector that the adapter received an interstitial.
-
Tells the connector that the adapter has received a unified mediated native ad.
mediatedUnifiedNativeAd is used by the Google Mobile Ads SDK to construct a unified native ad
object.
Declaration
Swift
func adapter(_ adapter: (any GADMAdNetworkAdapter)!, didReceive mediatedUnifiedNativeAd: (any MediatedUnifiedNativeAd)!)
-
Tells the connector that the adapter recorded a user click.
-
Tells the connector that the adapter will present a full screen modal.
-
Tells the connector that the adapter will dismiss a full screen modal.
-
Tells the connector that the adapter dismissed a full screen modal.
-
Tells the connector that the adapter will present an interstitial.
-
Tells the connector that the adapter will dismiss an interstitial.
-
Tells the connector that the adapter did dismiss an interstitial.
-
Deprecated
Use -adapterDidReceiveInterstitial:.
Deprecated. Use -adapterDidReceiveInterstitial:.
Declaration
Swift
func adapter(_ adapter: (any GADMAdNetworkAdapter)!, didReceiveInterstitial interstitial: NSObject!)
Objective-C
- (void)adapter:(id<GADMAdNetworkAdapter>)adapter
didReceiveInterstitial:(NSObject *)interstitial;
-
Deprecated
Use -adapterDidGetAdClick:.
Deprecated. Use -adapterDidGetAdClick:.
-
Deprecated
Use -adapter:didFailAd:
Deprecated. Use -adapter:didFailAd:.
-
Deprecated
Deprecated. No replacement.
Deprecated. No replacement.
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\u003eGADMAdNetworkConnector\u003c/code\u003e protocol facilitates communication between ad network adapters and the Google Mobile Ads SDK.\u003c/p\u003e\n"],["\u003cp\u003eAdapters use the connector to get information like ad volume and preferred view controllers for presenting ads.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eGADMAdNetworkConnector\u003c/code\u003e protocol includes callbacks to inform the Google Mobile Ads SDK about ad events, like receiving an ad or an ad click.\u003c/p\u003e\n"],["\u003cp\u003eSeveral older methods of the \u003ccode\u003eGADMAdNetworkConnector\u003c/code\u003e are now deprecated and should no longer be used.\u003c/p\u003e\n"]]],[],null,["# GoogleMobileAds Framework Reference\n\nGADMAdNetworkConnector\n======================\n\n @protocol GADMAdNetworkConnector \u003c../Protocols/GADMediationAdRequest.html\u003e\n\nAd network adapters interact with the mediation SDK using an object that implements the\nGADMAdNetworkConnector protocol. The connector object can be used to obtain necessary\ninformation for ad requests, and to call back to the mediation SDK on ad request returns and\nuser interactions.\n- `\n ``\n ``\n `\n\n ### [-viewControllerForPresentingModalView](#/c:objc(pl)GADMAdNetworkConnector(im)viewControllerForPresentingModalView)\n\n `\n ` \n When you need to show a landing page or any other modal view, such as when a user clicks or when\n your Ads SDK needs to show an interstitial, use this method to obtain a UIViewController that\n you can use to show your modal view. Call the -presentViewController:animated:completion: method\n of the returned UIViewController. \n\n #### Declaration\n\n Swift \n\n func viewControllerForPresentingModalView() -\u003e UIViewController!\n\n Objective-C \n\n - (UIViewController *)viewControllerForPresentingModalView;\n\n- `\n ``\n ``\n `\n\n ### [-adVolume](#/c:objc(pl)GADMAdNetworkConnector(im)adVolume)\n\n `\n ` \n Returns the preferred ad volume as a fraction of system volume (0.0 to 1.0). \n\n #### Declaration\n\n Swift \n\n func adVolume() -\u003e Float\n\n Objective-C \n\n - (float)adVolume;\n\n- `\n ``\n ``\n `\n\n ### [-adMuted](#/c:objc(pl)GADMAdNetworkConnector(im)adMuted)\n\n `\n ` \n Returns whether the ad should be muted. \n\n #### Declaration\n\n Swift \n\n func adMuted() -\u003e Bool\n\n Objective-C \n\n - (BOOL)adMuted;\n\n[Adapter Callbacks\n-----------------](#/Adapter-Callbacks)\n\n- `\n ``\n ``\n `\n\n ### [-adapter:didFailAd:](#/c:objc(pl)GADMAdNetworkConnector(im)adapter:didFailAd:)\n\n `\n ` \n Tells the connector that the adapter failed to receive an ad. \n\n #### Declaration\n\n Swift \n\n func adapter(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!, didFailAd error: (any Error)!)\n\n Objective-C \n\n - (void)adapter:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter didFailAd:(NSError *)error;\n\n- `\n ``\n ``\n `\n\n ### [-adapter:didReceiveAdView:](#/c:objc(pl)GADMAdNetworkConnector(im)adapter:didReceiveAdView:)\n\n `\n ` \n Tells the connector that the adapter received a banner ad. \n\n #### Declaration\n\n Swift \n\n func adapter(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!, didReceiveAdView view: UIView!)\n\n Objective-C \n\n - (void)adapter:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter\n didReceiveAdView:(UIView *)view;\n\n- `\n ``\n ``\n `\n\n ### [-adapterDidReceiveInterstitial:](#/c:objc(pl)GADMAdNetworkConnector(im)adapterDidReceiveInterstitial:)\n\n `\n ` \n Tells the connector that the adapter received an interstitial. \n\n #### Declaration\n\n Swift \n\n func adapterDidReceiveInterstitial(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!)\n\n Objective-C \n\n - (void)adapterDidReceiveInterstitial:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter;\n\n- `\n ``\n ``\n `\n\n ### [-adapter:didReceiveMediatedUnifiedNativeAd:](#/c:objc(pl)GADMAdNetworkConnector(im)adapter:didReceiveMediatedUnifiedNativeAd:)\n\n `\n ` \n Tells the connector that the adapter has received a unified mediated native ad.\n mediatedUnifiedNativeAd is used by the Google Mobile Ads SDK to construct a unified native ad\n object. \n\n #### Declaration\n\n Swift \n\n func adapter(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!, didReceive mediatedUnifiedNativeAd: (any MediatedUnifiedNativeAd)!)\n\n Objective-C \n\n - (void)adapter:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter\n didReceiveMediatedUnifiedNativeAd:\n (id\u003c../Protocols/GADMediatedUnifiedNativeAd.html\u003e)mediatedUnifiedNativeAd;\n\n[Ad events\n---------](#/Ad-events)\n\n- `\n ``\n ``\n `\n\n ### [-adapterDidGetAdClick:](#/c:objc(pl)GADMAdNetworkConnector(im)adapterDidGetAdClick:)\n\n `\n ` \n Tells the connector that the adapter recorded a user click. \n\n #### Declaration\n\n Swift \n\n func adapterDidGetAdClick(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!)\n\n Objective-C \n\n - (void)adapterDidGetAdClick:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter;\n\n- `\n ``\n ``\n `\n\n ### [-adapterWillPresentFullScreenModal:](#/c:objc(pl)GADMAdNetworkConnector(im)adapterWillPresentFullScreenModal:)\n\n `\n ` \n Tells the connector that the adapter will present a full screen modal. \n\n #### Declaration\n\n Swift \n\n func adapterWillPresentFullScreenModal(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!)\n\n Objective-C \n\n - (void)adapterWillPresentFullScreenModal:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter;\n\n- `\n ``\n ``\n `\n\n ### [-adapterWillDismissFullScreenModal:](#/c:objc(pl)GADMAdNetworkConnector(im)adapterWillDismissFullScreenModal:)\n\n `\n ` \n Tells the connector that the adapter will dismiss a full screen modal. \n\n #### Declaration\n\n Swift \n\n func adapterWillDismissFullScreenModal(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!)\n\n Objective-C \n\n - (void)adapterWillDismissFullScreenModal:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter;\n\n- `\n ``\n ``\n `\n\n ### [-adapterDidDismissFullScreenModal:](#/c:objc(pl)GADMAdNetworkConnector(im)adapterDidDismissFullScreenModal:)\n\n `\n ` \n Tells the connector that the adapter dismissed a full screen modal. \n\n #### Declaration\n\n Swift \n\n func adapterDidDismissFullScreenModal(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!)\n\n Objective-C \n\n - (void)adapterDidDismissFullScreenModal:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter;\n\n- `\n ``\n ``\n `\n\n ### [-adapterWillPresentInterstitial:](#/c:objc(pl)GADMAdNetworkConnector(im)adapterWillPresentInterstitial:)\n\n `\n ` \n Tells the connector that the adapter will present an interstitial. \n\n #### Declaration\n\n Swift \n\n func adapterWillPresentInterstitial(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!)\n\n Objective-C \n\n - (void)adapterWillPresentInterstitial:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter;\n\n- `\n ``\n ``\n `\n\n ### [-adapterWillDismissInterstitial:](#/c:objc(pl)GADMAdNetworkConnector(im)adapterWillDismissInterstitial:)\n\n `\n ` \n Tells the connector that the adapter will dismiss an interstitial. \n\n #### Declaration\n\n Swift \n\n func adapterWillDismissInterstitial(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!)\n\n Objective-C \n\n - (void)adapterWillDismissInterstitial:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter;\n\n- `\n ``\n ``\n `\n\n ### [-adapterDidDismissInterstitial:](#/c:objc(pl)GADMAdNetworkConnector(im)adapterDidDismissInterstitial:)\n\n `\n ` \n Tells the connector that the adapter did dismiss an interstitial. \n\n #### Declaration\n\n Swift \n\n func adapterDidDismissInterstitial(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!)\n\n Objective-C \n\n - (void)adapterDidDismissInterstitial:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter;\n\n[Deprecated\n----------](#/Deprecated)\n\n- `\n ``\n ``\n `\n\n ### [-adapter:didReceiveInterstitial:](#/c:objc(pl)GADMAdNetworkConnector(im)adapter:didReceiveInterstitial:)\n\n `\n ` \n Deprecated\n\n Use -adapterDidReceiveInterstitial:. \n Deprecated. Use -adapterDidReceiveInterstitial:. \n\n #### Declaration\n\n Swift \n\n func adapter(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!, didReceiveInterstitial interstitial: NSObject!)\n\n Objective-C \n\n - (void)adapter:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter\n didReceiveInterstitial:(NSObject *)interstitial;\n\n- `\n ``\n ``\n `\n\n ### [-adapter:clickDidOccurInBanner:](#/c:objc(pl)GADMAdNetworkConnector(im)adapter:clickDidOccurInBanner:)\n\n `\n ` \n Deprecated\n\n Use -adapterDidGetAdClick:. \n Deprecated. Use -adapterDidGetAdClick:. \n\n #### Declaration\n\n Swift \n\n func adapter(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!, clickDidOccurInBanner view: UIView!)\n\n Objective-C \n\n - (void)adapter:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter\n clickDidOccurInBanner:(UIView *)view;\n\n- `\n ``\n ``\n `\n\n ### [-adapter:didFailInterstitial:](#/c:objc(pl)GADMAdNetworkConnector(im)adapter:didFailInterstitial:)\n\n `\n ` \n Deprecated\n\n Use -adapter:didFailAd: \n Deprecated. Use -adapter:didFailAd:. \n\n #### Declaration\n\n Swift \n\n func adapter(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!, didFailInterstitial error: (any Error)!)\n\n Objective-C \n\n - (void)adapter:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter\n didFailInterstitial:(NSError *)error;\n\n- `\n ``\n ``\n `\n\n ### [-adapterWillLeaveApplication:](#/c:objc(pl)GADMAdNetworkConnector(im)adapterWillLeaveApplication:)\n\n `\n ` \n Deprecated\n\n Deprecated. No replacement. \n Deprecated. No replacement. \n\n #### Declaration\n\n Swift \n\n func adapterWillLeaveApplication(_ adapter: (any ../Protocols/GADMAdNetworkAdapter.html)!)\n\n Objective-C \n\n - (void)adapterWillLeaveApplication:(id\u003c../Protocols/GADMAdNetworkAdapter.html\u003e)adapter;"]]