Files
recipes/models/PaginatedSyncLogList.ts

97 lines
2.3 KiB
TypeScript

/* 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 { exists, mapValues } from '../runtime';
import type { SyncLog } from './SyncLog';
import {
SyncLogFromJSON,
SyncLogFromJSONTyped,
SyncLogToJSON,
} from './SyncLog';
/**
*
* @export
* @interface PaginatedSyncLogList
*/
export interface PaginatedSyncLogList {
/**
*
* @type {number}
* @memberof PaginatedSyncLogList
*/
count?: number;
/**
*
* @type {string}
* @memberof PaginatedSyncLogList
*/
next?: string | null;
/**
*
* @type {string}
* @memberof PaginatedSyncLogList
*/
previous?: string | null;
/**
*
* @type {Array<SyncLog>}
* @memberof PaginatedSyncLogList
*/
results?: Array<SyncLog>;
}
/**
* Check if a given object implements the PaginatedSyncLogList interface.
*/
export function instanceOfPaginatedSyncLogList(value: object): boolean {
let isInstance = true;
return isInstance;
}
export function PaginatedSyncLogListFromJSON(json: any): PaginatedSyncLogList {
return PaginatedSyncLogListFromJSONTyped(json, false);
}
export function PaginatedSyncLogListFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaginatedSyncLogList {
if ((json === undefined) || (json === null)) {
return json;
}
return {
'count': !exists(json, 'count') ? undefined : json['count'],
'next': !exists(json, 'next') ? undefined : json['next'],
'previous': !exists(json, 'previous') ? undefined : json['previous'],
'results': !exists(json, 'results') ? undefined : ((json['results'] as Array<any>).map(SyncLogFromJSON)),
};
}
export function PaginatedSyncLogListToJSON(value?: PaginatedSyncLogList | null): any {
if (value === undefined) {
return undefined;
}
if (value === null) {
return null;
}
return {
'count': value.count,
'next': value.next,
'previous': value.previous,
'results': value.results === undefined ? undefined : ((value.results as Array<any>).map(SyncLogToJSON)),
};
}