Skip to content

Commit

Permalink
Update genre IDs
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisKruegerDev committed Mar 12, 2024
1 parent 63e8c39 commit b52296b
Show file tree
Hide file tree
Showing 4 changed files with 1,077 additions and 31 deletions.
Original file line number Diff line number Diff line change
@@ -1,15 +1,8 @@
package app.moviebase.tmdb.model

@Deprecated("Use TmdbGenreId.Movie instead")
object TmdbMovieGenreId {
const val ACTION = 28
const val ADVENTURE = 12
}

object TmdbGenreId {

object Movie {

const val ACTION = 28
const val ADVENTURE = 12
const val ANIMATION = 16
Expand All @@ -28,7 +21,7 @@ object TmdbGenreId {
const val TV_MOVIE = 10770
const val THRILLER = 53
const val WAR = 10752
const val WESTERM = 37
const val WESTERN = 37

val ALL = setOf(
ACTION,
Expand All @@ -49,67 +42,47 @@ object TmdbGenreId {
TV_MOVIE,
THRILLER,
WAR,
WESTERM
WESTERN,
)

fun contains(genreId: Int) = ALL.contains(genreId)
}

object Show {
const val ACTION = 28
const val ADVENTURE = 12
const val ACTION_ADVENTURE = 10759
const val ANIMATION = 16
const val COMEDY = 35
const val CRIME = 80
const val DOCUMENTARY = 99
const val DRAMA = 18
const val FAMILY = 10751
const val FANTASY = 14
const val KIDS = 10762
const val MYSTERY = 9648
const val HISTORY = 36
const val HORROR = 27
const val MUSIC = 10402
const val NEWS = 10763
const val REALITY = 10764
const val SCIENCE_FICTION_FANTASY = 10765
const val SCIENCE_FICTION = 878
const val SOAP = 10766
const val TALK = 10767
const val WAR_POLITICS = 10768
const val ROMANCE = 10749
const val THRILLER = 53
const val WAR = 10752
const val WESTERN = 37

val ALL = setOf(
ACTION,
ADVENTURE,
ACTION_ADVENTURE,
ANIMATION,
COMEDY,
CRIME,
DOCUMENTARY,
DRAMA,
FAMILY,
FANTASY,
KIDS,
MYSTERY,
HISTORY,
HORROR,
MUSIC,
NEWS,
REALITY,
SCIENCE_FICTION_FANTASY,
SCIENCE_FICTION,
SOAP,
TALK,
WAR_POLITICS,
ROMANCE,
THRILLER,
WAR,
WESTERN
WESTERN,
)

fun contains(genreId: Int) = ALL.contains(genreId)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,6 @@ sealed interface TmdbPersonCredit : TmdbAnyItem, TmdbBackdropItem, TmdbPosterIte
) : TmdbPersonCredit
}


@Serializable
enum class TmdbDepartment(val value: String) {

Expand Down Expand Up @@ -365,6 +364,9 @@ enum class TmdbDepartment(val value: String) {
@SerialName("Editing")
EDITING("Editing"),

@SerialName("Actors")
ACTORS("Actors"),

@SerialName("Crew")
CREW("Crew");

Expand Down
Loading

0 comments on commit b52296b

Please sign in to comment.