301 lines
10 KiB
TypeScript
301 lines
10 KiB
TypeScript
/* 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';
|
|
import type { KeepUntil } from './KeepUntil';
|
|
import {
|
|
KeepUntilFromJSON,
|
|
KeepUntilFromJSONTyped,
|
|
KeepUntilToJSON,
|
|
} from './KeepUntil';
|
|
import type { RecordingStatus } from './RecordingStatus';
|
|
import {
|
|
RecordingStatusFromJSON,
|
|
RecordingStatusFromJSONTyped,
|
|
RecordingStatusToJSON,
|
|
} from './RecordingStatus';
|
|
import type { TimerInfoDtoProgramInfo } from './TimerInfoDtoProgramInfo';
|
|
import {
|
|
TimerInfoDtoProgramInfoFromJSON,
|
|
TimerInfoDtoProgramInfoFromJSONTyped,
|
|
TimerInfoDtoProgramInfoToJSON,
|
|
} from './TimerInfoDtoProgramInfo';
|
|
|
|
/**
|
|
*
|
|
* @export
|
|
* @interface CreateTimerRequest
|
|
*/
|
|
export interface CreateTimerRequest {
|
|
/**
|
|
* Gets or sets the Id of the recording.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
id?: string | null;
|
|
/**
|
|
*
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
type?: string | null;
|
|
/**
|
|
* Gets or sets the server identifier.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
serverId?: string | null;
|
|
/**
|
|
* Gets or sets the external identifier.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
externalId?: string | null;
|
|
/**
|
|
* Gets or sets the channel id of the recording.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
channelId?: string;
|
|
/**
|
|
* Gets or sets the external channel identifier.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
externalChannelId?: string | null;
|
|
/**
|
|
* Gets or sets the channel name of the recording.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
channelName?: string | null;
|
|
/**
|
|
*
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
channelPrimaryImageTag?: string | null;
|
|
/**
|
|
* Gets or sets the program identifier.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
programId?: string | null;
|
|
/**
|
|
* Gets or sets the external program identifier.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
externalProgramId?: string | null;
|
|
/**
|
|
* Gets or sets the name of the recording.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
name?: string | null;
|
|
/**
|
|
* Gets or sets the description of the recording.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
overview?: string | null;
|
|
/**
|
|
* Gets or sets the start date of the recording, in UTC.
|
|
* @type {Date}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
startDate?: Date;
|
|
/**
|
|
* Gets or sets the end date of the recording, in UTC.
|
|
* @type {Date}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
endDate?: Date;
|
|
/**
|
|
* Gets or sets the name of the service.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
serviceName?: string | null;
|
|
/**
|
|
* Gets or sets the priority.
|
|
* @type {number}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
priority?: number;
|
|
/**
|
|
* Gets or sets the pre padding seconds.
|
|
* @type {number}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
prePaddingSeconds?: number;
|
|
/**
|
|
* Gets or sets the post padding seconds.
|
|
* @type {number}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
postPaddingSeconds?: number;
|
|
/**
|
|
* Gets or sets a value indicating whether this instance is pre padding required.
|
|
* @type {boolean}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
isPrePaddingRequired?: boolean;
|
|
/**
|
|
* Gets or sets the Id of the Parent that has a backdrop if the item does not have one.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
parentBackdropItemId?: string | null;
|
|
/**
|
|
* Gets or sets the parent backdrop image tags.
|
|
* @type {Array<string>}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
parentBackdropImageTags?: Array<string> | null;
|
|
/**
|
|
* Gets or sets a value indicating whether this instance is post padding required.
|
|
* @type {boolean}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
isPostPaddingRequired?: boolean;
|
|
/**
|
|
*
|
|
* @type {KeepUntil}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
keepUntil?: KeepUntil;
|
|
/**
|
|
*
|
|
* @type {RecordingStatus}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
status?: RecordingStatus;
|
|
/**
|
|
* Gets or sets the series timer identifier.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
seriesTimerId?: string | null;
|
|
/**
|
|
* Gets or sets the external series timer identifier.
|
|
* @type {string}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
externalSeriesTimerId?: string | null;
|
|
/**
|
|
* Gets or sets the run time ticks.
|
|
* @type {number}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
runTimeTicks?: number | null;
|
|
/**
|
|
*
|
|
* @type {TimerInfoDtoProgramInfo}
|
|
* @memberof CreateTimerRequest
|
|
*/
|
|
programInfo?: TimerInfoDtoProgramInfo | null;
|
|
}
|
|
|
|
/**
|
|
* Check if a given object implements the CreateTimerRequest interface.
|
|
*/
|
|
export function instanceOfCreateTimerRequest(value: object): boolean {
|
|
let isInstance = true;
|
|
|
|
return isInstance;
|
|
}
|
|
|
|
export function CreateTimerRequestFromJSON(json: any): CreateTimerRequest {
|
|
return CreateTimerRequestFromJSONTyped(json, false);
|
|
}
|
|
|
|
export function CreateTimerRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateTimerRequest {
|
|
if ((json === undefined) || (json === null)) {
|
|
return json;
|
|
}
|
|
return {
|
|
|
|
'id': !exists(json, 'Id') ? undefined : json['Id'],
|
|
'type': !exists(json, 'Type') ? undefined : json['Type'],
|
|
'serverId': !exists(json, 'ServerId') ? undefined : json['ServerId'],
|
|
'externalId': !exists(json, 'ExternalId') ? undefined : json['ExternalId'],
|
|
'channelId': !exists(json, 'ChannelId') ? undefined : json['ChannelId'],
|
|
'externalChannelId': !exists(json, 'ExternalChannelId') ? undefined : json['ExternalChannelId'],
|
|
'channelName': !exists(json, 'ChannelName') ? undefined : json['ChannelName'],
|
|
'channelPrimaryImageTag': !exists(json, 'ChannelPrimaryImageTag') ? undefined : json['ChannelPrimaryImageTag'],
|
|
'programId': !exists(json, 'ProgramId') ? undefined : json['ProgramId'],
|
|
'externalProgramId': !exists(json, 'ExternalProgramId') ? undefined : json['ExternalProgramId'],
|
|
'name': !exists(json, 'Name') ? undefined : json['Name'],
|
|
'overview': !exists(json, 'Overview') ? undefined : json['Overview'],
|
|
'startDate': !exists(json, 'StartDate') ? undefined : (new Date(json['StartDate'])),
|
|
'endDate': !exists(json, 'EndDate') ? undefined : (new Date(json['EndDate'])),
|
|
'serviceName': !exists(json, 'ServiceName') ? undefined : json['ServiceName'],
|
|
'priority': !exists(json, 'Priority') ? undefined : json['Priority'],
|
|
'prePaddingSeconds': !exists(json, 'PrePaddingSeconds') ? undefined : json['PrePaddingSeconds'],
|
|
'postPaddingSeconds': !exists(json, 'PostPaddingSeconds') ? undefined : json['PostPaddingSeconds'],
|
|
'isPrePaddingRequired': !exists(json, 'IsPrePaddingRequired') ? undefined : json['IsPrePaddingRequired'],
|
|
'parentBackdropItemId': !exists(json, 'ParentBackdropItemId') ? undefined : json['ParentBackdropItemId'],
|
|
'parentBackdropImageTags': !exists(json, 'ParentBackdropImageTags') ? undefined : json['ParentBackdropImageTags'],
|
|
'isPostPaddingRequired': !exists(json, 'IsPostPaddingRequired') ? undefined : json['IsPostPaddingRequired'],
|
|
'keepUntil': !exists(json, 'KeepUntil') ? undefined : KeepUntilFromJSON(json['KeepUntil']),
|
|
'status': !exists(json, 'Status') ? undefined : RecordingStatusFromJSON(json['Status']),
|
|
'seriesTimerId': !exists(json, 'SeriesTimerId') ? undefined : json['SeriesTimerId'],
|
|
'externalSeriesTimerId': !exists(json, 'ExternalSeriesTimerId') ? undefined : json['ExternalSeriesTimerId'],
|
|
'runTimeTicks': !exists(json, 'RunTimeTicks') ? undefined : json['RunTimeTicks'],
|
|
'programInfo': !exists(json, 'ProgramInfo') ? undefined : TimerInfoDtoProgramInfoFromJSON(json['ProgramInfo']),
|
|
};
|
|
}
|
|
|
|
export function CreateTimerRequestToJSON(value?: CreateTimerRequest | null): any {
|
|
if (value === undefined) {
|
|
return undefined;
|
|
}
|
|
if (value === null) {
|
|
return null;
|
|
}
|
|
return {
|
|
|
|
'Id': value.id,
|
|
'Type': value.type,
|
|
'ServerId': value.serverId,
|
|
'ExternalId': value.externalId,
|
|
'ChannelId': value.channelId,
|
|
'ExternalChannelId': value.externalChannelId,
|
|
'ChannelName': value.channelName,
|
|
'ChannelPrimaryImageTag': value.channelPrimaryImageTag,
|
|
'ProgramId': value.programId,
|
|
'ExternalProgramId': value.externalProgramId,
|
|
'Name': value.name,
|
|
'Overview': value.overview,
|
|
'StartDate': value.startDate === undefined ? undefined : (value.startDate.toISOString()),
|
|
'EndDate': value.endDate === undefined ? undefined : (value.endDate.toISOString()),
|
|
'ServiceName': value.serviceName,
|
|
'Priority': value.priority,
|
|
'PrePaddingSeconds': value.prePaddingSeconds,
|
|
'PostPaddingSeconds': value.postPaddingSeconds,
|
|
'IsPrePaddingRequired': value.isPrePaddingRequired,
|
|
'ParentBackdropItemId': value.parentBackdropItemId,
|
|
'ParentBackdropImageTags': value.parentBackdropImageTags,
|
|
'IsPostPaddingRequired': value.isPostPaddingRequired,
|
|
'KeepUntil': KeepUntilToJSON(value.keepUntil),
|
|
'Status': RecordingStatusToJSON(value.status),
|
|
'SeriesTimerId': value.seriesTimerId,
|
|
'ExternalSeriesTimerId': value.externalSeriesTimerId,
|
|
'RunTimeTicks': value.runTimeTicks,
|
|
'ProgramInfo': TimerInfoDtoProgramInfoToJSON(value.programInfo),
|
|
};
|
|
}
|
|
|