OOAdPlugin.h
1 #import <Foundation/Foundation.h>
2 
3 #ifndef OOAdPlugin_h
4 #define OOAdPlugin_h
5 
6 @protocol OOPlayerProtocol;
7 @protocol OOLifeCycle;
8 
13 @protocol OOAdPlugin<NSObject, OOLifeCycle>
14 
20 - (BOOL)onContentChanged;
21 
27 - (BOOL)onInitialPlay;
28 
34 - (BOOL)onPlayheadUpdate:(Float64)playhead;
35 
41 - (BOOL)onContentFinished; // put your postrolls here
42 
48 - (BOOL)onCuePoint:(int)cuePointIndex;
49 
55 - (BOOL)onContentError:(int)errorCode;
56 
60 - (void)onAdModeEntered;
61 
69 
73 - (void)resetAds;
74 
79 - (void)skipAd;
80 
84 - (void)clickAd;
85 
89 - (NSSet *)getCuePointsAtSeconds;
90 
95 - (void)onAdIconClicked: (NSInteger) index;
96 
102 - (BOOL)hasNotNilAds;
103 
104 @end
105 
106 #endif /* OOAdPlugin_h */
BOOL onContentFinished()
This is called before finishing playing content so plugin can play postroll.
NSSet * getCuePointsAtSeconds()
Handle events around the lifecycle of the OOOoyalaPlayer.
Definition: OOLifeCycle.h:10
void onAdModeEntered()
This is called when control is handed over to the plugin.
BOOL onContentChanged()
This is called when content changed.
BOOL onInitialPlay()
This is called before start playing content so plugin can play preroll.
id< OOPlayerProtocol > player()
This is called ooyala UI pass down UI related events.
An interface to implement an Ad Plugin, which can plug into the OoyalaPlayer.
Definition: OOAdPlugin.h:13
BOOL hasNotNilAds()
Called to check if we&#39;re not dealing with nil ads.
void clickAd()
This is called when the ad is clicked.
void resetAds()
This is called to reset all ads to unplayed.
void skipAd()
This is called to skip the current ad.
Definition: OOPlayerProtocol.h:17