/* tslint:disable */ /* eslint-disable */ /** * Tandoor * Tandoor API Docs * * The version of the OpenAPI document: 0.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 { SourceImportIngredient } from './SourceImportIngredient'; import { SourceImportIngredientFromJSON, SourceImportIngredientFromJSONTyped, SourceImportIngredientToJSON, SourceImportIngredientToJSONTyped, } from './SourceImportIngredient'; /** * * @export * @interface SourceImportStep */ export interface SourceImportStep { /** * * @type {string} * @memberof SourceImportStep */ instruction: string; /** * * @type {Array} * @memberof SourceImportStep */ ingredients: Array; /** * * @type {boolean} * @memberof SourceImportStep */ showIngredientsTable: boolean; } /** * Check if a given object implements the SourceImportStep interface. */ export function instanceOfSourceImportStep(value: object): value is SourceImportStep { if (!('instruction' in value) || value['instruction'] === undefined) return false; if (!('ingredients' in value) || value['ingredients'] === undefined) return false; if (!('showIngredientsTable' in value) || value['showIngredientsTable'] === undefined) return false; return true; } export function SourceImportStepFromJSON(json: any): SourceImportStep { return SourceImportStepFromJSONTyped(json, false); } export function SourceImportStepFromJSONTyped(json: any, ignoreDiscriminator: boolean): SourceImportStep { if (json == null) { return json; } return { 'instruction': json['instruction'], 'ingredients': ((json['ingredients'] as Array).map(SourceImportIngredientFromJSON)), 'showIngredientsTable': json['show_ingredients_table'], }; } export function SourceImportStepToJSON(json: any): SourceImportStep { return SourceImportStepToJSONTyped(json, false); } export function SourceImportStepToJSONTyped(value?: SourceImportStep | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'instruction': value['instruction'], 'ingredients': ((value['ingredients'] as Array).map(SourceImportIngredientToJSON)), 'show_ingredients_table': value['showIngredientsTable'], }; }