An implementation of IMAContentPlayhead for AVPlayer. Use this class to
provide content tracking if your content player of choice is an AVPlayer
or its subclass.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-20 UTC."],[[["\u003cp\u003eIMAAVPlayerContentPlayhead is designed to track the content progress of an AVPlayer or its subclasses.\u003c/p\u003e\n"],["\u003cp\u003eIt implements the IMAContentPlayhead protocol, providing a standard way to monitor playback.\u003c/p\u003e\n"],["\u003cp\u003eIt utilizes a periodic time observer attached to the AVPlayer to track playback time.\u003c/p\u003e\n"],["\u003cp\u003eInitialization requires an AVPlayer instance and immediately begins tracking.\u003c/p\u003e\n"]]],["The `IMAAVPlayerContentPlayhead` class tracks an `AVPlayer` for content playhead information. It's initialized with an `AVPlayer` instance via `initWithAVPlayer:`. Upon initialization, it immediately adds a periodic time observer to the provided player. The `player` property returns the tracked `AVPlayer` instance, enabling content tracking for AVPlayer-based media. The main actions are initializing and tracking using a AVPlayer instance.\n"],null,["# GoogleInteractiveMediaAds Framework Reference\n\nIMAAVPlayerContentPlayhead\n==========================\n\n @interface IMAAVPlayerContentPlayhead : NSObject \u003c../Protocols/IMAContentPlayhead.html\u003e\n\nAn implementation of IMAContentPlayhead for AVPlayer. Use this class to\nprovide content tracking if your content player of choice is an AVPlayer\nor its subclass.\n- `\n ``\n ``\n `\n\n ### [player](#/c:objc(cs)IMAAVPlayerContentPlayhead(py)player)\n\n `\n ` \n The player to track. \n\n #### Declaration\n\n Swift \n\n var player: AVPlayer { get }\n\n Objective-C \n\n @property (nonatomic, readonly) AVPlayer *_Nonnull player;\n\n- `\n ``\n ``\n `\n\n ### [-initWithAVPlayer:](#/c:objc(cs)IMAAVPlayerContentPlayhead(im)initWithAVPlayer:)\n\n `\n ` \n Initializes a IMAAVPlayerContentPlayhead that tracks a player. It will attach a periodic time\n observer to the player immediately. \n\n #### Declaration\n\n Swift \n\n init(avPlayer player: AVPlayer)\n\n Objective-C \n\n - (nonnull instancetype)initWithAVPlayer:(nonnull AVPlayer *)player;\n\n #### Parameters\n\n |----------------|------------------------|\n | ` `*player*` ` | the AVPlayer to track. |\n\n #### Return Value\n\n the IMAAVPlayerContentPlayhead instance"]]