cwmsjs
Version:
CWMS Data API Library for JavaScript/TypeScript created with OpenAPI generator for use with browser webapps
37 lines (36 loc) • 1.3 kB
JavaScript
/* tslint:disable */
/* eslint-disable */
/**
* CWMS Data API
* CWMS REST API for Data Retrieval
*
* The version of the OpenAPI document: 2.3.2-2025.03.19
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import { instanceOfLocationCatalogEntry, LocationCatalogEntryFromJSONTyped, LocationCatalogEntryToJSON, } from './LocationCatalogEntry';
import { instanceOfTimeSeriesCatalogEntry, TimeSeriesCatalogEntryFromJSONTyped, TimeSeriesCatalogEntryToJSON, } from './TimeSeriesCatalogEntry';
export function CatalogEntryFromJSON(json) {
return CatalogEntryFromJSONTyped(json, false);
}
export function CatalogEntryFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return Object.assign(Object.assign({}, LocationCatalogEntryFromJSONTyped(json, true)), TimeSeriesCatalogEntryFromJSONTyped(json, true));
}
export function CatalogEntryToJSON(value) {
if (value == null) {
return value;
}
if (instanceOfLocationCatalogEntry(value)) {
return LocationCatalogEntryToJSON(value);
}
if (instanceOfTimeSeriesCatalogEntry(value)) {
return TimeSeriesCatalogEntryToJSON(value);
}
return {};
}