/* tslint:disable */ /* eslint-disable */ /** * My API * API documentation for my Laravel app * * 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 { CategoryFrontendResource } from './CategoryFrontendResource'; import { CategoryFrontendResourceFromJSON, CategoryFrontendResourceFromJSONTyped, CategoryFrontendResourceToJSON, CategoryFrontendResourceToJSONTyped, } from './CategoryFrontendResource'; /** * * @export * @interface CategoryWithChildrenFrontendResource */ export interface CategoryWithChildrenFrontendResource { /** * * @type {CategoryFrontendResource} * @memberof CategoryWithChildrenFrontendResource */ category: CategoryFrontendResource | null; /** * * @type {Array} * @memberof CategoryWithChildrenFrontendResource */ children: Array | null; } /** * Check if a given object implements the CategoryWithChildrenFrontendResource interface. */ export function instanceOfCategoryWithChildrenFrontendResource(value: object): value is CategoryWithChildrenFrontendResource { if (!('category' in value) || value['category'] === undefined) return false; if (!('children' in value) || value['children'] === undefined) return false; return true; } export function CategoryWithChildrenFrontendResourceFromJSON(json: any): CategoryWithChildrenFrontendResource { return CategoryWithChildrenFrontendResourceFromJSONTyped(json, false); } export function CategoryWithChildrenFrontendResourceFromJSONTyped(json: any, ignoreDiscriminator: boolean): CategoryWithChildrenFrontendResource { if (json == null) { return json; } return { 'category': CategoryFrontendResourceFromJSON(json['category']), 'children': (json['children'] == null ? null : (json['children'] as Array).map(CategoryFrontendResourceFromJSON)), }; } export function CategoryWithChildrenFrontendResourceToJSON(json: any): CategoryWithChildrenFrontendResource { return CategoryWithChildrenFrontendResourceToJSONTyped(json, false); } export function CategoryWithChildrenFrontendResourceToJSONTyped(value?: CategoryWithChildrenFrontendResource | null, ignoreDiscriminator: boolean = false): any { if (value == null) { return value; } return { 'category': CategoryFrontendResourceToJSON(value['category']), 'children': (value['children'] == null ? null : (value['children'] as Array).map(CategoryFrontendResourceToJSON)), }; }