UNPKG

fetch-jsd

Version:

A simple and typed library, based on OpenAPI spec from developer.atlassian.com, for accessing product APIs.

56 lines (55 loc) 2.56 kB
"use strict"; // tslint:disable /** * Service Desk Public REST API * Public REST API for Jira Service Desk * * The version of the OpenAPI document: 1001.0.0-SNAPSHOT * * * 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 }); const runtime_1 = require("../runtime"); const _1 = require("./"); function SlaInformationOngoingCycleDTOFromJSON(json) { return SlaInformationOngoingCycleDTOFromJSONTyped(json, false); } exports.SlaInformationOngoingCycleDTOFromJSON = SlaInformationOngoingCycleDTOFromJSON; function SlaInformationOngoingCycleDTOFromJSONTyped(json, ignoreDiscriminator) { if ((json === undefined) || (json === null)) { return json; } return { 'startTime': !runtime_1.exists(json, 'startTime') ? undefined : _1.DateDTOFromJSON(json['startTime']), 'breachTime': !runtime_1.exists(json, 'breachTime') ? undefined : _1.DateDTOFromJSON(json['breachTime']), 'breached': !runtime_1.exists(json, 'breached') ? undefined : json['breached'], 'paused': !runtime_1.exists(json, 'paused') ? undefined : json['paused'], 'withinCalendarHours': !runtime_1.exists(json, 'withinCalendarHours') ? undefined : json['withinCalendarHours'], 'goalDuration': !runtime_1.exists(json, 'goalDuration') ? undefined : _1.DurationDTOFromJSON(json['goalDuration']), 'elapsedTime': !runtime_1.exists(json, 'elapsedTime') ? undefined : _1.DurationDTOFromJSON(json['elapsedTime']), 'remainingTime': !runtime_1.exists(json, 'remainingTime') ? undefined : _1.DurationDTOFromJSON(json['remainingTime']), }; } exports.SlaInformationOngoingCycleDTOFromJSONTyped = SlaInformationOngoingCycleDTOFromJSONTyped; function SlaInformationOngoingCycleDTOToJSON(value) { if (value === undefined) { return undefined; } if (value === null) { return null; } return { 'startTime': _1.DateDTOToJSON(value.startTime), 'breachTime': _1.DateDTOToJSON(value.breachTime), 'breached': value.breached, 'paused': value.paused, 'withinCalendarHours': value.withinCalendarHours, 'goalDuration': _1.DurationDTOToJSON(value.goalDuration), 'elapsedTime': _1.DurationDTOToJSON(value.elapsedTime), 'remainingTime': _1.DurationDTOToJSON(value.remainingTime), }; } exports.SlaInformationOngoingCycleDTOToJSON = SlaInformationOngoingCycleDTOToJSON;