GoogleInteractiveMediaAds Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
IMAAdError
@interface IMAAdError : NSObject
Surfaces an error that occurred during ad loading or playing.
-
The type of error that occurred during ad loading or ad playing.
Declaration
Objective-C
@property (nonatomic, readonly) IMAErrorType type;
-
The error code for obtaining more specific information about the error.
Declaration
Objective-C
@property (nonatomic, readonly) IMAErrorCode code;
-
A brief description about the error.
Declaration
Swift
var message: String? { get }
Objective-C
@property (nonatomic, copy, readonly, nullable) NSString *message;
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\u003e\u003ccode\u003eIMAAdError\u003c/code\u003e objects provide information about errors that occur during ad loading or playback.\u003c/p\u003e\n"],["\u003cp\u003eThese errors are categorized by \u003ccode\u003etype\u003c/code\u003e, have a specific \u003ccode\u003ecode\u003c/code\u003e for further details, and may include a descriptive \u003ccode\u003emessage\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eDevelopers can use the \u003ccode\u003etype\u003c/code\u003e, \u003ccode\u003ecode\u003c/code\u003e, and \u003ccode\u003emessage\u003c/code\u003e properties of an \u003ccode\u003eIMAAdError\u003c/code\u003e to understand and handle ad-related errors in their applications.\u003c/p\u003e\n"]]],["The `IMAAdError` class surfaces errors during ad loading or playing. It provides three key pieces of information: the `type` of error (from `IMAErrorType`), an error `code` (from `IMAErrorCode`) for detailed information, and a descriptive `message` about the error. These properties are read-only and allow for the identification and analysis of issues encountered during ad operations. They can be accessed via Swift or Objective-C.\n"],null,["# GoogleInteractiveMediaAds Framework Reference\n\nIMAAdError\n==========\n\n @interface IMAAdError : NSObject\n\nSurfaces an error that occurred during ad loading or playing.\n- `\n ``\n ``\n `\n\n ### [type](#/c:objc(cs)IMAAdError(py)type)\n\n `\n ` \n The type of error that occurred during ad loading or ad playing. \n\n #### Declaration\n\n Swift \n\n var type: ../Enums/IMAErrorType.html { get }\n\n Objective-C \n\n @property (nonatomic, readonly) ../Enums/IMAErrorType.html type;\n\n- `\n ``\n ``\n `\n\n ### [code](#/c:objc(cs)IMAAdError(py)code)\n\n `\n ` \n The error code for obtaining more specific information about the error. \n\n #### Declaration\n\n Swift \n\n var code: ../Enums/IMAErrorCode.html { get }\n\n Objective-C \n\n @property (nonatomic, readonly) ../Enums/IMAErrorCode.html code;\n\n- `\n ``\n ``\n `\n\n ### [message](#/c:objc(cs)IMAAdError(py)message)\n\n `\n ` \n A brief description about the error. \n\n #### Declaration\n\n Swift \n\n var message: String? { get }\n\n Objective-C \n\n @property (nonatomic, copy, readonly, nullable) NSString *message;"]]