-
Notifications
You must be signed in to change notification settings - Fork 30
Expand file tree
/
Copy pathGoogleDai.ts
More file actions
33 lines (30 loc) · 1 KB
/
GoogleDai.ts
File metadata and controls
33 lines (30 loc) · 1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/**
* The Google DAI API.
*
* @category Ads
* @public
*/
export interface GoogleDAI {
/**
* Returns the content time without ads for a given stream time. Returns the given stream time for live streams.
*
* @param time - The stream time with inserted ads (in seconds).
*/
contentTimeForStreamTime(time: number): Promise<number>;
/**
* Returns the stream time with ads for a given content time. Returns the given content time for live streams.
*
* @param time - The content time without any ads (in seconds).
*/
streamTimeForContentTime(time: number): Promise<number>;
/**
* Whether snapback is enabled. When enabled and the user seeks over multiple ad breaks, the last ad break that was seeked past will be played.
*
* @defaultValue `true`
*/
readonly snapback: Promise<boolean>;
/**
* Set snapback value. When enabled and the user seeks over multiple ad breaks, the last ad break that was seeked past will be played.
*/
setSnapback(enabled: boolean): void;
}