/* 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 { FacetColumnRequestFromJSON, FacetColumnRequestToJSON, } from './FacetColumnRequest';
import { QueryFilterFromJSON, QueryFilterToJSON, } from './QueryFilter';
import { SortItemFromJSON, SortItemToJSON, } from './SortItem';
/**
 * Check if a given object implements the TableQuery interface.
 */
export function instanceOfTableQuery(value) {
    return true;
}
export function TableQueryFromJSON(json) {
    return TableQueryFromJSONTyped(json, false);
}
export function TableQueryFromJSONTyped(json, ignoreDiscriminator) {
    if (json == null) {
        return json;
    }
    return {
        'sql': json['sql'] == null ? undefined : json['sql'],
        'additionalFilters': json['additionalFilters'] == null ? undefined : (json['additionalFilters'].map(QueryFilterFromJSON)),
        'selectedFacets': json['selectedFacets'] == null ? undefined : (json['selectedFacets'].map(FacetColumnRequestFromJSON)),
        'includeEntityEtag': json['includeEntityEtag'] == null ? undefined : json['includeEntityEtag'],
        'selectFileColumn': json['selectFileColumn'] == null ? undefined : json['selectFileColumn'],
        'selectFileVersionColumn': json['selectFileVersionColumn'] == null ? undefined : json['selectFileVersionColumn'],
        'offset': json['offset'] == null ? undefined : json['offset'],
        'limit': json['limit'] == null ? undefined : json['limit'],
        'sort': json['sort'] == null ? undefined : (json['sort'].map(SortItemFromJSON)),
    };
}
export function TableQueryToJSON(json) {
    return TableQueryToJSONTyped(json, false);
}
export function TableQueryToJSONTyped(value, ignoreDiscriminator = false) {
    if (value == null) {
        return value;
    }
    return {
        'sql': value['sql'],
        'additionalFilters': value['additionalFilters'] == null ? undefined : (value['additionalFilters'].map(QueryFilterToJSON)),
        'selectedFacets': value['selectedFacets'] == null ? undefined : (value['selectedFacets'].map(FacetColumnRequestToJSON)),
        'includeEntityEtag': value['includeEntityEtag'],
        'selectFileColumn': value['selectFileColumn'],
        'selectFileVersionColumn': value['selectFileVersionColumn'],
        'offset': value['offset'],
        'limit': value['limit'],
        'sort': value['sort'] == null ? undefined : (value['sort'].map(SortItemToJSON)),
    };
}
//# sourceMappingURL=TableQuery.js.map