commonMain.org.jellyfin.sdk.model.api.BaseItemKind.kt Maven / Gradle / Ivy
// !! WARNING
// !! DO NOT EDIT THIS FILE
//
// This file is generated by the openapi-generator module and is not meant for manual changes.
// Please read the README.md file in the openapi-generator module for additional information.
package org.jellyfin.sdk.model.api
import kotlin.String
import kotlin.requireNotNull
import kotlinx.serialization.SerialName
import kotlinx.serialization.Serializable
/**
* The base item kind.
*/
@Serializable
public enum class BaseItemKind(
public val serialName: String,
) {
@SerialName("AggregateFolder")
AGGREGATE_FOLDER("AggregateFolder"),
@SerialName("Audio")
AUDIO("Audio"),
@SerialName("AudioBook")
AUDIO_BOOK("AudioBook"),
@SerialName("BasePluginFolder")
BASE_PLUGIN_FOLDER("BasePluginFolder"),
@SerialName("Book")
BOOK("Book"),
@SerialName("BoxSet")
BOX_SET("BoxSet"),
@SerialName("Channel")
CHANNEL("Channel"),
@SerialName("ChannelFolderItem")
CHANNEL_FOLDER_ITEM("ChannelFolderItem"),
@SerialName("CollectionFolder")
COLLECTION_FOLDER("CollectionFolder"),
@SerialName("Episode")
EPISODE("Episode"),
@SerialName("Folder")
FOLDER("Folder"),
@SerialName("Genre")
GENRE("Genre"),
@SerialName("ManualPlaylistsFolder")
MANUAL_PLAYLISTS_FOLDER("ManualPlaylistsFolder"),
@SerialName("Movie")
MOVIE("Movie"),
@SerialName("LiveTvChannel")
LIVE_TV_CHANNEL("LiveTvChannel"),
@SerialName("LiveTvProgram")
LIVE_TV_PROGRAM("LiveTvProgram"),
@SerialName("MusicAlbum")
MUSIC_ALBUM("MusicAlbum"),
@SerialName("MusicArtist")
MUSIC_ARTIST("MusicArtist"),
@SerialName("MusicGenre")
MUSIC_GENRE("MusicGenre"),
@SerialName("MusicVideo")
MUSIC_VIDEO("MusicVideo"),
@SerialName("Person")
PERSON("Person"),
@SerialName("Photo")
PHOTO("Photo"),
@SerialName("PhotoAlbum")
PHOTO_ALBUM("PhotoAlbum"),
@SerialName("Playlist")
PLAYLIST("Playlist"),
@SerialName("PlaylistsFolder")
PLAYLISTS_FOLDER("PlaylistsFolder"),
@SerialName("Program")
PROGRAM("Program"),
@SerialName("Recording")
RECORDING("Recording"),
@SerialName("Season")
SEASON("Season"),
@SerialName("Series")
SERIES("Series"),
@SerialName("Studio")
STUDIO("Studio"),
@SerialName("Trailer")
TRAILER("Trailer"),
@SerialName("TvChannel")
TV_CHANNEL("TvChannel"),
@SerialName("TvProgram")
TV_PROGRAM("TvProgram"),
@SerialName("UserRootFolder")
USER_ROOT_FOLDER("UserRootFolder"),
@SerialName("UserView")
USER_VIEW("UserView"),
@SerialName("Video")
VIDEO("Video"),
@SerialName("Year")
YEAR("Year"),
;
/**
* Get the serial name of the enum member.
*/
override fun toString(): String = serialName
public companion object {
/**
* Find the enum member by the serial name or return null.
*/
public fun fromNameOrNull(serialName: String): BaseItemKind? = when (serialName) {
"AggregateFolder" -> AGGREGATE_FOLDER
"Audio" -> AUDIO
"AudioBook" -> AUDIO_BOOK
"BasePluginFolder" -> BASE_PLUGIN_FOLDER
"Book" -> BOOK
"BoxSet" -> BOX_SET
"Channel" -> CHANNEL
"ChannelFolderItem" -> CHANNEL_FOLDER_ITEM
"CollectionFolder" -> COLLECTION_FOLDER
"Episode" -> EPISODE
"Folder" -> FOLDER
"Genre" -> GENRE
"ManualPlaylistsFolder" -> MANUAL_PLAYLISTS_FOLDER
"Movie" -> MOVIE
"LiveTvChannel" -> LIVE_TV_CHANNEL
"LiveTvProgram" -> LIVE_TV_PROGRAM
"MusicAlbum" -> MUSIC_ALBUM
"MusicArtist" -> MUSIC_ARTIST
"MusicGenre" -> MUSIC_GENRE
"MusicVideo" -> MUSIC_VIDEO
"Person" -> PERSON
"Photo" -> PHOTO
"PhotoAlbum" -> PHOTO_ALBUM
"Playlist" -> PLAYLIST
"PlaylistsFolder" -> PLAYLISTS_FOLDER
"Program" -> PROGRAM
"Recording" -> RECORDING
"Season" -> SEASON
"Series" -> SERIES
"Studio" -> STUDIO
"Trailer" -> TRAILER
"TvChannel" -> TV_CHANNEL
"TvProgram" -> TV_PROGRAM
"UserRootFolder" -> USER_ROOT_FOLDER
"UserView" -> USER_VIEW
"Video" -> VIDEO
"Year" -> YEAR
else -> null
}
/**
* Find the enum member by the serial name or throw.
*/
public fun fromName(serialName: String): BaseItemKind =
requireNotNull(fromNameOrNull(serialName)) { """Unknown value $serialName""" }
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy