aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models/redundancy/videos-redundancy-strategy.model.ts
blob: 15409abf06582714a0ed4860730c2c92b3a027a6 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
export type VideoRedundancyStrategy = 'most-views' | 'trending' | 'recently-added'
export type VideoRedundancyStrategyWithManual = VideoRedundancyStrategy | 'manual'

export type MostViewsRedundancyStrategy = {
  strategy: 'most-views'
  size: number
  minLifetime: number
}

export type TrendingRedundancyStrategy = {
  strategy: 'trending'
  size: number
  minLifetime: number
}

export type RecentlyAddedStrategy = {
  strategy: 'recently-added'
  size: number
  minViews: number
  minLifetime: number
}

export type VideosRedundancyStrategy = MostViewsRedundancyStrategy | TrendingRedundancyStrategy | RecentlyAddedStrategy