/* tslint:disable */ /* eslint-disable */ /** * BMLT * BMLT Admin API Documentation * * The version of the OpenAPI document: 1.0.0 * * * 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 { FormatTranslation } from './FormatTranslation'; import { FormatTranslationFromJSON, FormatTranslationFromJSONTyped, FormatTranslationToJSON, FormatTranslationToJSONTyped, } from './FormatTranslation'; /** * * @export * @interface Format */ export interface Format { /** * * @type {string} * @memberof Format */ worldId: string; /** * * @type {string} * @memberof Format */ type: string; /** * * @type {Array} * @memberof Format */ translations: Array; /** * * @type {number} * @memberof Format */ id: number; } /** * Check if a given object implements the Format interface. */ export function instanceOfFormat(value: object): value is Format { if (!('worldId' in value) || value['worldId'] === undefined) return false; if (!('type' in value) || value['type'] === undefined) return false; if (!('translations' in value) || value['translations'] === undefined) return false; if (!('id' in value) || value['id'] === undefined) return false; return true; } export function FormatFromJSON(json: any): Format { return FormatFromJSONTyped(json, false); } export function FormatFromJSONTyped(json: any, ignoreDiscriminator: boolean): Format { if (json == null) { return json; } return { 'worldId': json['worldId'], 'type': json['type'], 'translations': ((json['translations'] as Array).map(FormatTranslationFromJSON)), 'id': json['id'], }; } export function FormatToJSON(json: any): Format { return FormatToJSONTyped(json, false); } export function FormatToJSONTyped(value?: Format | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'worldId': value['worldId'], 'type': value['type'], 'translations': ((value['translations'] as Array).map(FormatTranslationToJSON)), 'id': value['id'], }; }