UNPKG

cwmsjs

Version:

CWMS Data API Library for JavaScript/TypeScript created with OpenAPI generator for use with browser webapps

80 lines (71 loc) 1.84 kB
/* tslint:disable */ /* eslint-disable */ /** * CWMS Data API * CWMS REST API for Data Retrieval * * The version of the OpenAPI document: 2.4.0-2026.3.16 * * * 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 { CwmsId, CwmsIdFromJSON, CwmsIdFromJSONTyped, CwmsIdToJSON, } from './CwmsId'; /** * * @export * @interface PumpLocation */ export interface PumpLocation { /** * * @type {CwmsId} * @memberof PumpLocation */ pumpIn?: CwmsId; /** * * @type {CwmsId} * @memberof PumpLocation */ pumpOut?: CwmsId; /** * * @type {CwmsId} * @memberof PumpLocation */ pumpBelow?: CwmsId; } export function PumpLocationFromJSON(json: any): PumpLocation { return PumpLocationFromJSONTyped(json, false); } export function PumpLocationFromJSONTyped(json: any, ignoreDiscriminator: boolean): PumpLocation { if ((json === undefined) || (json === null)) { return json; } return { 'pumpIn': !exists(json, 'pump-in') ? undefined : CwmsIdFromJSON(json['pump-in']), 'pumpOut': !exists(json, 'pump-out') ? undefined : CwmsIdFromJSON(json['pump-out']), 'pumpBelow': !exists(json, 'pump-below') ? undefined : CwmsIdFromJSON(json['pump-below']), }; } export function PumpLocationToJSON(value?: PumpLocation | null): any { if (value === undefined) { return undefined; } if (value === null) { return null; } return { 'pump-in': CwmsIdToJSON(value.pumpIn), 'pump-out': CwmsIdToJSON(value.pumpOut), 'pump-below': CwmsIdToJSON(value.pumpBelow), }; }