UNPKG

fastcomments-sdk

Version:

FastComments API Client - A SDK for interacting with the FastComments API

60 lines 2.21 kB
"use strict"; /* tslint:disable */ /* eslint-disable */ /** * fastcomments * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * 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. */ Object.defineProperty(exports, "__esModule", { value: true }); exports.instanceOfAggregationOperation = instanceOfAggregationOperation; exports.AggregationOperationFromJSON = AggregationOperationFromJSON; exports.AggregationOperationFromJSONTyped = AggregationOperationFromJSONTyped; exports.AggregationOperationToJSON = AggregationOperationToJSON; exports.AggregationOperationToJSONTyped = AggregationOperationToJSONTyped; const AggregationOpType_1 = require("./AggregationOpType"); /** * Check if a given object implements the AggregationOperation interface. */ function instanceOfAggregationOperation(value) { if (!('field' in value) || value['field'] === undefined) return false; if (!('op' in value) || value['op'] === undefined) return false; return true; } function AggregationOperationFromJSON(json) { return AggregationOperationFromJSONTyped(json, false); } function AggregationOperationFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'field': json['field'], 'op': (0, AggregationOpType_1.AggregationOpTypeFromJSON)(json['op']), 'alias': json['alias'] == null ? undefined : json['alias'], 'expandArray': json['expandArray'] == null ? undefined : json['expandArray'], }; } function AggregationOperationToJSON(json) { return AggregationOperationToJSONTyped(json, false); } function AggregationOperationToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'field': value['field'], 'op': (0, AggregationOpType_1.AggregationOpTypeToJSON)(value['op']), 'alias': value['alias'], 'expandArray': value['expandArray'], }; } //# sourceMappingURL=AggregationOperation.js.map