]>
Commit | Line | Data |
---|---|---|
453e83ea | 1 | import { VideoStreamingPlaylistModel } from '../../../models/video/video-streaming-playlist' |
b5fecbf4 | 2 | import { PickWith, PickWithOpt } from '../../utils' |
453e83ea | 3 | import { MVideoRedundancyFileUrl } from './video-redundancy' |
b5fecbf4 | 4 | import { MVideo, MVideoUrl } from '@server/typings/models' |
453e83ea | 5 | |
0283eaac C |
6 | type Use<K extends keyof VideoStreamingPlaylistModel, M> = PickWith<VideoStreamingPlaylistModel, K, M> |
7 | ||
8 | // ############################################################################ | |
9 | ||
453e83ea C |
10 | export type MStreamingPlaylist = Omit<VideoStreamingPlaylistModel, 'Video' | 'RedundancyVideos'> |
11 | ||
12 | export type MStreamingPlaylistVideo = MStreamingPlaylist & | |
0283eaac | 13 | Use<'Video', MVideo> |
453e83ea C |
14 | |
15 | export type MStreamingPlaylistRedundancies = MStreamingPlaylist & | |
0283eaac | 16 | Use<'RedundancyVideos', MVideoRedundancyFileUrl[]> |
b5fecbf4 C |
17 | |
18 | export type MStreamingPlaylistRedundanciesOpt = MStreamingPlaylist & | |
19 | PickWithOpt<VideoStreamingPlaylistModel, 'RedundancyVideos', MVideoRedundancyFileUrl[]> |