Stay organized with collections
Save and categorize content based on your preferences.
public class AdMediaInfo
The minimal information required to play an ad. Note that multiple AdMediaInfo objects may resolve to the same content, but refer to different ads. Thus when comparing AdMediaInfo objects one should use the identity equality check, as opposed to comparing their URLs.
Summary
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\u003eAdMediaInfo\u003c/code\u003e objects contain the minimum data needed for ad playback.\u003c/p\u003e\n"],["\u003cp\u003eDifferent \u003ccode\u003eAdMediaInfo\u003c/code\u003e objects might point to the same content but represent separate ads, requiring identity checks for comparison instead of URL comparisons.\u003c/p\u003e\n"],["\u003cp\u003eThe primary information accessible via \u003ccode\u003eAdMediaInfo\u003c/code\u003e is the ad's URL, retrieved using the \u003ccode\u003egetUrl()\u003c/code\u003e method.\u003c/p\u003e\n"]]],[],null,["# AdMediaInfo\n===========\n\n[Kotlin](/ad-manager/dynamic-ad-insertion/sdk/android/api/reference/kotlin/com/google/ads/interactivemedia/v3/api/player/AdMediaInfo \"View this page in Kotlin\") \\|Java \n\n\n```\npublic class AdMediaInfo\n```\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nThe minimal information required to play an ad. Note that multiple AdMediaInfo objects may resolve to the same content, but refer to different ads. Thus when comparing AdMediaInfo objects one should use the identity equality check, as opposed to comparing their URLs.\n\nSummary\n-------\n\n| ### Public fields |\n|---------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------|\n| `final `[String](https://developer.android.com/reference/java/lang/String.html) | [url](/ad-manager/dynamic-ad-insertion/sdk/android/api/reference/com/google/ads/interactivemedia/v3/api/player/AdMediaInfo#url()) |\n\n| ### Public methods |\n|-------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------|\n| [String](https://developer.android.com/reference/java/lang/String.html) | [getUrl](/ad-manager/dynamic-ad-insertion/sdk/android/api/reference/com/google/ads/interactivemedia/v3/api/player/AdMediaInfo#getUrl())`()` |\n\nPublic fields\n-------------\n\n### url\n\n```\npublic final String url\n``` \n\nPublic methods\n--------------\n\n### getUrl\n\n```\npublic String getUrl()\n```"]]