/*
 * Jellyfin API
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 10.11.6
 * 
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */

package org.openhab.binding.jellyfin.internal.gen.current.model;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;

/**
 * The base item kind.
 */
public enum BaseItemKind {
    AGGREGATE_FOLDER("AggregateFolder"),
    AUDIO("Audio"),
    AUDIO_BOOK("AudioBook"),
    BASE_PLUGIN_FOLDER("BasePluginFolder"),
    BOOK("Book"),
    BOX_SET("BoxSet"),
    CHANNEL("Channel"),
    CHANNEL_FOLDER_ITEM("ChannelFolderItem"),
    COLLECTION_FOLDER("CollectionFolder"),
    EPISODE("Episode"),
    FOLDER("Folder"),
    GENRE("Genre"),
    LIVE_TV_CHANNEL("LiveTvChannel"),
    LIVE_TV_PROGRAM("LiveTvProgram"),
    MANUAL_PLAYLISTS_FOLDER("ManualPlaylistsFolder"),
    MOVIE("Movie"),
    MUSIC_ALBUM("MusicAlbum"),
    MUSIC_ARTIST("MusicArtist"),
    MUSIC_GENRE("MusicGenre"),
    MUSIC_VIDEO("MusicVideo"),
    PERSON("Person"),
    PHOTO("Photo"),
    PHOTO_ALBUM("PhotoAlbum"),
    PLAYLIST("Playlist"),
    PLAYLISTS_FOLDER("PlaylistsFolder"),
    PROGRAM("Program"),
    RECORDING("Recording"),
    SEASON("Season"),
    SERIES("Series"),
    STUDIO("Studio"),
    TRAILER("Trailer"),
    TV_CHANNEL("TvChannel"),
    TV_PROGRAM("TvProgram"),
    USER_ROOT_FOLDER("UserRootFolder"),
    USER_VIEW("UserView"),
    VIDEO("Video"),
    YEAR("Year");

    private String value;

    BaseItemKind(String value) {
        this.value = value;
    }

    @JsonValue
    public String getValue() {
        return value;
    }

    @Override
    public String toString() {
        return String.valueOf(value);
    }

    @JsonCreator
    public static BaseItemKind fromValue(String value) {
        for (BaseItemKind b : BaseItemKind.values()) {
            if (b.value.equals(value)) {
                return b;
            }
        }
        throw new IllegalArgumentException("Unexpected value '" + value + "'");
    }

    /**
     * Convert the instance into URL query string.
     *
     * @param prefix prefix of the query string
     * @return URL query string
     */
    public String toUrlQueryString(String prefix) {
        if (prefix == null) {
            prefix = "";
        }

        return String.format(java.util.Locale.ROOT, "%s=%s", prefix, this.toString());
    }
}
