jellyfin-discord-bot/server/jellyfin/models/SyncPlayBufferingRequest.ts

90 lines
2.6 KiB
TypeScript
Raw Permalink Normal View History

2023-05-04 23:34:53 +02:00
/* tslint:disable */
/* eslint-disable */
/**
* Jellyfin API
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 10.8.9
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import { exists, mapValues } from '../runtime';
/**
* Class BufferRequestDto.
* @export
* @interface SyncPlayBufferingRequest
*/
export interface SyncPlayBufferingRequest {
/**
* Gets or sets when the request has been made by the client.
* @type {Date}
* @memberof SyncPlayBufferingRequest
*/
when?: Date;
/**
* Gets or sets the position ticks.
* @type {number}
* @memberof SyncPlayBufferingRequest
*/
positionTicks?: number;
/**
* Gets or sets a value indicating whether the client playback is unpaused.
* @type {boolean}
* @memberof SyncPlayBufferingRequest
*/
isPlaying?: boolean;
/**
* Gets or sets the playlist item identifier of the playing item.
* @type {string}
* @memberof SyncPlayBufferingRequest
*/
playlistItemId?: string;
}
/**
* Check if a given object implements the SyncPlayBufferingRequest interface.
*/
export function instanceOfSyncPlayBufferingRequest(value: object): boolean {
let isInstance = true;
return isInstance;
}
export function SyncPlayBufferingRequestFromJSON(json: any): SyncPlayBufferingRequest {
return SyncPlayBufferingRequestFromJSONTyped(json, false);
}
export function SyncPlayBufferingRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): SyncPlayBufferingRequest {
if ((json === undefined) || (json === null)) {
return json;
}
return {
'when': !exists(json, 'When') ? undefined : (new Date(json['When'])),
'positionTicks': !exists(json, 'PositionTicks') ? undefined : json['PositionTicks'],
'isPlaying': !exists(json, 'IsPlaying') ? undefined : json['IsPlaying'],
'playlistItemId': !exists(json, 'PlaylistItemId') ? undefined : json['PlaylistItemId'],
};
}
export function SyncPlayBufferingRequestToJSON(value?: SyncPlayBufferingRequest | null): any {
if (value === undefined) {
return undefined;
}
if (value === null) {
return null;
}
return {
'When': value.when === undefined ? undefined : (value.when.toISOString()),
'PositionTicks': value.positionTicks,
'IsPlaying': value.isPlaying,
'PlaylistItemId': value.playlistItemId,
};
}