2019-08-15 04:53:26 -05:00
|
|
|
import { VideoStreamingPlaylistModel } from '../../../models/video/video-streaming-playlist'
|
|
|
|
import { PickWith } from '../../utils'
|
|
|
|
import { MVideoRedundancyFileUrl } from './video-redundancy'
|
|
|
|
import { MVideo } from '@server/typings/models'
|
|
|
|
|
2019-08-20 06:52:49 -05:00
|
|
|
type Use<K extends keyof VideoStreamingPlaylistModel, M> = PickWith<VideoStreamingPlaylistModel, K, M>
|
|
|
|
|
|
|
|
// ############################################################################
|
|
|
|
|
2019-08-15 04:53:26 -05:00
|
|
|
export type MStreamingPlaylist = Omit<VideoStreamingPlaylistModel, 'Video' | 'RedundancyVideos'>
|
|
|
|
|
|
|
|
export type MStreamingPlaylistVideo = MStreamingPlaylist &
|
2019-08-20 06:52:49 -05:00
|
|
|
Use<'Video', MVideo>
|
2019-08-15 04:53:26 -05:00
|
|
|
|
|
|
|
export type MStreamingPlaylistRedundancies = MStreamingPlaylist &
|
2019-08-20 06:52:49 -05:00
|
|
|
Use<'RedundancyVideos', MVideoRedundancyFileUrl[]>
|