123 lines
4.1 KiB
TypeScript
123 lines
4.1 KiB
TypeScript
/* tslint:disable */
|
|
/* eslint-disable */
|
|
/**
|
|
* @fastify/swagger
|
|
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
*
|
|
* The version of the OpenAPI document: 9.6.1
|
|
*
|
|
*
|
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
* https://openapi-generator.tech
|
|
* Do not edit the class manually.
|
|
*/
|
|
|
|
import { mapValues } from '../runtime';
|
|
import type { TttHistory200ResponsePayloadDataInnerPlayerX } from './TttHistory200ResponsePayloadDataInnerPlayerX';
|
|
import {
|
|
TttHistory200ResponsePayloadDataInnerPlayerXFromJSON,
|
|
TttHistory200ResponsePayloadDataInnerPlayerXFromJSONTyped,
|
|
TttHistory200ResponsePayloadDataInnerPlayerXToJSON,
|
|
TttHistory200ResponsePayloadDataInnerPlayerXToJSONTyped,
|
|
} from './TttHistory200ResponsePayloadDataInnerPlayerX';
|
|
|
|
/**
|
|
*
|
|
* @export
|
|
* @interface TttHistory200ResponsePayloadDataInner
|
|
*/
|
|
export interface TttHistory200ResponsePayloadDataInner {
|
|
/**
|
|
*
|
|
* @type {string}
|
|
* @memberof TttHistory200ResponsePayloadDataInner
|
|
*/
|
|
gameId: string;
|
|
/**
|
|
*
|
|
* @type {TttHistory200ResponsePayloadDataInnerPlayerX}
|
|
* @memberof TttHistory200ResponsePayloadDataInner
|
|
*/
|
|
playerX: TttHistory200ResponsePayloadDataInnerPlayerX;
|
|
/**
|
|
*
|
|
* @type {TttHistory200ResponsePayloadDataInnerPlayerX}
|
|
* @memberof TttHistory200ResponsePayloadDataInner
|
|
*/
|
|
playerO: TttHistory200ResponsePayloadDataInnerPlayerX;
|
|
/**
|
|
*
|
|
* @type {string}
|
|
* @memberof TttHistory200ResponsePayloadDataInner
|
|
*/
|
|
date: string;
|
|
/**
|
|
*
|
|
* @type {string}
|
|
* @memberof TttHistory200ResponsePayloadDataInner
|
|
*/
|
|
outcome: TttHistory200ResponsePayloadDataInnerOutcomeEnum;
|
|
}
|
|
|
|
|
|
/**
|
|
* @export
|
|
*/
|
|
export const TttHistory200ResponsePayloadDataInnerOutcomeEnum = {
|
|
WinX: 'winX',
|
|
WinO: 'winO',
|
|
Other: 'other',
|
|
Draw: 'draw'
|
|
} as const;
|
|
export type TttHistory200ResponsePayloadDataInnerOutcomeEnum = typeof TttHistory200ResponsePayloadDataInnerOutcomeEnum[keyof typeof TttHistory200ResponsePayloadDataInnerOutcomeEnum];
|
|
|
|
|
|
/**
|
|
* Check if a given object implements the TttHistory200ResponsePayloadDataInner interface.
|
|
*/
|
|
export function instanceOfTttHistory200ResponsePayloadDataInner(value: object): value is TttHistory200ResponsePayloadDataInner {
|
|
if (!('gameId' in value) || value['gameId'] === undefined) return false;
|
|
if (!('playerX' in value) || value['playerX'] === undefined) return false;
|
|
if (!('playerO' in value) || value['playerO'] === undefined) return false;
|
|
if (!('date' in value) || value['date'] === undefined) return false;
|
|
if (!('outcome' in value) || value['outcome'] === undefined) return false;
|
|
return true;
|
|
}
|
|
|
|
export function TttHistory200ResponsePayloadDataInnerFromJSON(json: any): TttHistory200ResponsePayloadDataInner {
|
|
return TttHistory200ResponsePayloadDataInnerFromJSONTyped(json, false);
|
|
}
|
|
|
|
export function TttHistory200ResponsePayloadDataInnerFromJSONTyped(json: any, ignoreDiscriminator: boolean): TttHistory200ResponsePayloadDataInner {
|
|
if (json == null) {
|
|
return json;
|
|
}
|
|
return {
|
|
|
|
'gameId': json['gameId'],
|
|
'playerX': TttHistory200ResponsePayloadDataInnerPlayerXFromJSON(json['playerX']),
|
|
'playerO': TttHistory200ResponsePayloadDataInnerPlayerXFromJSON(json['playerO']),
|
|
'date': json['date'],
|
|
'outcome': json['outcome'],
|
|
};
|
|
}
|
|
|
|
export function TttHistory200ResponsePayloadDataInnerToJSON(json: any): TttHistory200ResponsePayloadDataInner {
|
|
return TttHistory200ResponsePayloadDataInnerToJSONTyped(json, false);
|
|
}
|
|
|
|
export function TttHistory200ResponsePayloadDataInnerToJSONTyped(value?: TttHistory200ResponsePayloadDataInner | null, ignoreDiscriminator: boolean = false): any {
|
|
if (value == null) {
|
|
return value;
|
|
}
|
|
|
|
return {
|
|
|
|
'gameId': value['gameId'],
|
|
'playerX': TttHistory200ResponsePayloadDataInnerPlayerXToJSON(value['playerX']),
|
|
'playerO': TttHistory200ResponsePayloadDataInnerPlayerXToJSON(value['playerO']),
|
|
'date': value['date'],
|
|
'outcome': value['outcome'],
|
|
};
|
|
}
|
|
|