SCAdSequencer
@interface SCAdSequencer : NSObject
Use this class for instream use cases. Here you can specify each AdSlot, it´s timing and are able to reinsert over-scrubbed adSlots
-
The configuration object for the complete adSlot session
Declaration
Objective-C
@property (nonatomic, strong) SCAdConfiguration *_Nonnull configuration;
-
Set your view controller as delegate of the sequener to get informed about events etc.
Declaration
Objective-C
@property (nonatomic, weak) id<SCAdSequencerDelegate> _Nullable delegate;
-
Set your player implementation as facade delegate (so the sequnecer can talk to it)
Declaration
Objective-C
@property (nonatomic, weak) id<SCAdFacadeDelegate> _Nullable facadeDelegate;
-
The array of your adSlots
Declaration
Objective-C
@property (nonatomic, strong) NSMutableArray *_Nonnull adSlots;
-
The url of your content video
Declaration
Objective-C
@property (nonatomic, copy) NSString *_Nonnull contentURL;
-
Default initializer
Declaration
Objective-C
- (nonnull instancetype) initWithPlayerDelegate:(nonnull id<SCAdFacadeDelegate>)facadeDelegate sessionController:(nonnull SCAdSessionController *)sessionController;
-
Start the sequencer with this function
Declaration
Objective-C
- (void)startSequencer;
-
Stop the sequencer with this function
Declaration
Objective-C
- (void)stopSequencer;
-
Call this function to pause the sequencer
Declaration
Objective-C
- (void)pauseSequencer;
-
Call this function to resume the sequencer (if paused)
Declaration
Objective-C
- (void)resumeSequencer;
-
Call this function to to find out if the sequencer is paused
Declaration
Objective-C
- (BOOL)isPaused;
-
Call this function to cleanup the sequencer
Declaration
Objective-C
- (void)cleanup;
-
Call this function when the user has pushed the skip button
Declaration
Objective-C
- (void)skipAd;
-
Call this function for a more detailed adInfo
Declaration
Objective-C
- (void)getAdInfo:(nonnull SCAdInfoCompletionBlock)completion;
-
Get your publicAdSlot object here
Declaration
Objective-C
- (void)getPublicAdSlot:(nonnull SCPublicAdSlotCompletionBlock)completion;
-
Call this function when the user taps on the ad
Declaration
Objective-C
- (void)onClickThrough;
-
Add your playerView here for visibility checking
Declaration
Objective-C
- (void)addViewForVisibilityCheck:(id)view;
-
Register any view, that covers your adView but belongs to your ad playback views (like soundButton, replayButton etc.)
Declaration
Objective-C
- (void)registerFriendlyViews:(nonnull NSMutableArray *)friendlyViews;
-
Call this function for a detailed adError object
Declaration
Objective-C
- (void)getAdError:(nonnull SCAdErrorCompletionBlock)completion;
-
Call this function when the user presses the mute button (on or off)
Declaration
Objective-C
- (void)onMuteButtonPressed;
-
Calling this function triggers a call to getElementSize, call it when the size of the video player changes (e.g. going to or coming back from fullscreen)
Declaration
Objective-C
- (void)resize;
-
Call this function to receive the currentClickThroughURL as string
Declaration
Objective-C
- (void)clickTroughURL:(nonnull SCStringResultCompletionBlock)completion;
-
Call this function when you display the ViewController that contains this SCAdSlotController to help visibility checking
Declaration
Objective-C
- (void)activate:(BOOL)isActive;