/* tslint:disable */ /* eslint-disable */ /** * metrics-sdk-admin * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 5.4.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 { mapValues } from '../runtime'; import type { CardioMachineParseCode } from './CardioMachineParseCode'; import { CardioMachineParseCodeFromJSON, CardioMachineParseCodeFromJSONTyped, CardioMachineParseCodeToJSON, } from './CardioMachineParseCode'; import type { CardioExerciseData } from './CardioExerciseData'; import { CardioExerciseDataFromJSON, CardioExerciseDataFromJSONTyped, CardioExerciseDataToJSON, } from './CardioExerciseData'; /** * * @export * @interface CardioMachineData */ export interface CardioMachineData { /** * * @type {number} * @memberof CardioMachineData */ id: number; /** * * @type {string} * @memberof CardioMachineData */ name: string; /** * * @type {string} * @memberof CardioMachineData */ line: CardioMachineDataLineEnum; /** * * @type {CardioMachineParseCode} * @memberof CardioMachineData */ parseCode: CardioMachineParseCode; /** * * @type {number} * @memberof CardioMachineData */ defaultCardioExerciseId?: number; /** * * @type {string} * @memberof CardioMachineData */ machineTypeFallback?: string; /** * * @type {CardioExerciseData} * @memberof CardioMachineData */ defaultCardioExercise?: CardioExerciseData; } /** * @export */ export const CardioMachineDataLineEnum = { MSeries: 'mSeries' } as const; export type CardioMachineDataLineEnum = | 'mSeries' ; /** * Check if a given object implements the CardioMachineData interface. */ export function instanceOfCardioMachineData(value: object): value is CardioMachineData { if (!('id' in value) || value['id'] === undefined) return false; if (!('name' in value) || value['name'] === undefined) return false; if (!('line' in value) || value['line'] === undefined) return false; if (!('parseCode' in value) || value['parseCode'] === undefined) return false; return true; } export function CardioMachineDataFromJSON(json: any): CardioMachineData { return CardioMachineDataFromJSONTyped(json, false); } export function CardioMachineDataFromJSONTyped(json: any, ignoreDiscriminator: boolean): CardioMachineData { if (json == null) { return json; } return { 'id': json['id'], 'name': json['name'], 'line': json['line'], 'parseCode': CardioMachineParseCodeFromJSON(json['parseCode']), 'defaultCardioExerciseId': json['defaultCardioExerciseId'] == null ? undefined : json['defaultCardioExerciseId'], 'machineTypeFallback': json['machineTypeFallback'] == null ? undefined : json['machineTypeFallback'], 'defaultCardioExercise': json['defaultCardioExercise'] == null ? undefined : CardioExerciseDataFromJSON(json['defaultCardioExercise']), }; } export function CardioMachineDataToJSON(value?: CardioMachineData | null): any { if (value == null) { return value; } return { 'id': value['id'], 'name': value['name'], 'line': value['line'], 'parseCode': CardioMachineParseCodeToJSON(value['parseCode']), 'defaultCardioExerciseId': value['defaultCardioExerciseId'], 'machineTypeFallback': value['machineTypeFallback'], 'defaultCardioExercise': CardioExerciseDataToJSON(value['defaultCardioExercise']), }; }