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

89 lines
2.5 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';
import type { ForgotPasswordAction } from './ForgotPasswordAction';
import {
ForgotPasswordActionFromJSON,
ForgotPasswordActionFromJSONTyped,
ForgotPasswordActionToJSON,
} from './ForgotPasswordAction';
/**
*
* @export
* @interface ForgotPasswordResult
*/
export interface ForgotPasswordResult {
/**
*
* @type {ForgotPasswordAction}
* @memberof ForgotPasswordResult
*/
action?: ForgotPasswordAction;
/**
* Gets or sets the pin file.
* @type {string}
* @memberof ForgotPasswordResult
*/
pinFile?: string | null;
/**
* Gets or sets the pin expiration date.
* @type {Date}
* @memberof ForgotPasswordResult
*/
pinExpirationDate?: Date | null;
}
/**
* Check if a given object implements the ForgotPasswordResult interface.
*/
export function instanceOfForgotPasswordResult(value: object): boolean {
let isInstance = true;
return isInstance;
}
export function ForgotPasswordResultFromJSON(json: any): ForgotPasswordResult {
return ForgotPasswordResultFromJSONTyped(json, false);
}
export function ForgotPasswordResultFromJSONTyped(json: any, ignoreDiscriminator: boolean): ForgotPasswordResult {
if ((json === undefined) || (json === null)) {
return json;
}
return {
'action': !exists(json, 'Action') ? undefined : ForgotPasswordActionFromJSON(json['Action']),
'pinFile': !exists(json, 'PinFile') ? undefined : json['PinFile'],
'pinExpirationDate': !exists(json, 'PinExpirationDate') ? undefined : (json['PinExpirationDate'] === null ? null : new Date(json['PinExpirationDate'])),
};
}
export function ForgotPasswordResultToJSON(value?: ForgotPasswordResult | null): any {
if (value === undefined) {
return undefined;
}
if (value === null) {
return null;
}
return {
'Action': ForgotPasswordActionToJSON(value.action),
'PinFile': value.pinFile,
'PinExpirationDate': value.pinExpirationDate === undefined ? undefined : (value.pinExpirationDate === null ? null : value.pinExpirationDate.toISOString()),
};
}