/* tslint:disable */
/* eslint-disable */
/**
 * Synapse REST API
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: v1
 *
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */
import { ColumnModelFromJSON, ColumnModelToJSON, } from './ColumnModel';
import { CsvTableDescriptorFromJSON, CsvTableDescriptorToJSON, } from './CsvTableDescriptor';
/**
 * @export
 */
export const GridCsvImportRequestConcreteTypeEnum = {
    org_sagebionetworks_repo_model_grid_GridCsvImportRequest: 'org.sagebionetworks.repo.model.grid.GridCsvImportRequest'
};
/**
 * Check if a given object implements the GridCsvImportRequest interface.
 */
export function instanceOfGridCsvImportRequest(value) {
    if (!('concreteType' in value) || value['concreteType'] === undefined)
        return false;
    if (!Object.values(GridCsvImportRequestConcreteTypeEnum).includes(value["concreteType"])) {
        return false;
    }
    return true;
}
export function GridCsvImportRequestFromJSON(json) {
    return GridCsvImportRequestFromJSONTyped(json, false);
}
export function GridCsvImportRequestFromJSONTyped(json, ignoreDiscriminator) {
    if (json == null) {
        return json;
    }
    return {
        'concreteType': json['concreteType'],
        'sessionId': json['sessionId'] == null ? undefined : json['sessionId'],
        'fileHandleId': json['fileHandleId'] == null ? undefined : json['fileHandleId'],
        'csvDescriptor': json['csvDescriptor'] == null ? undefined : CsvTableDescriptorFromJSON(json['csvDescriptor']),
        'schema': json['schema'] == null ? undefined : (json['schema'].map(ColumnModelFromJSON)),
    };
}
export function GridCsvImportRequestToJSON(json) {
    return GridCsvImportRequestToJSONTyped(json, false);
}
export function GridCsvImportRequestToJSONTyped(value, ignoreDiscriminator = false) {
    if (value == null) {
        return value;
    }
    return {
        'concreteType': value['concreteType'],
        'sessionId': value['sessionId'],
        'fileHandleId': value['fileHandleId'],
        'csvDescriptor': CsvTableDescriptorToJSON(value['csvDescriptor']),
        'schema': value['schema'] == null ? undefined : (value['schema'].map(ColumnModelToJSON)),
    };
}
//# sourceMappingURL=GridCsvImportRequest.js.map