UNPKG

fastcomments-sdk

Version:

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

125 lines 6.52 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.instanceOfGetCommentsPublicResponse = instanceOfGetCommentsPublicResponse; exports.GetCommentsPublicResponseFromJSON = GetCommentsPublicResponseFromJSON; exports.GetCommentsPublicResponseFromJSONTyped = GetCommentsPublicResponseFromJSONTyped; exports.GetCommentsPublicResponseToJSON = GetCommentsPublicResponseToJSON; exports.GetCommentsPublicResponseToJSONTyped = GetCommentsPublicResponseToJSONTyped; const CustomConfigParameters_1 = require("./CustomConfigParameters"); const PublicComment_1 = require("./PublicComment"); const APIStatus_1 = require("./APIStatus"); const UserSessionInfo_1 = require("./UserSessionInfo"); /** * Check if a given object implements the GetCommentsPublicResponse interface. */ function instanceOfGetCommentsPublicResponse(value) { if (!('status' in value) || value['status'] === undefined) return false; if (!('code' in value) || value['code'] === undefined) return false; if (!('reason' in value) || value['reason'] === undefined) return false; if (!('comments' in value) || value['comments'] === undefined) return false; if (!('user' in value) || value['user'] === undefined) return false; if (!('pageNumber' in value) || value['pageNumber'] === undefined) return false; return true; } function GetCommentsPublicResponseFromJSON(json) { return GetCommentsPublicResponseFromJSONTyped(json, false); } function GetCommentsPublicResponseFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'statusCode': json['statusCode'] == null ? undefined : json['statusCode'], 'status': (0, APIStatus_1.APIStatusFromJSON)(json['status']), 'code': json['code'], 'reason': json['reason'], 'translatedWarning': json['translatedWarning'] == null ? undefined : json['translatedWarning'], 'comments': (json['comments'].map(PublicComment_1.PublicCommentFromJSON)), 'user': (0, UserSessionInfo_1.UserSessionInfoFromJSON)(json['user']), 'urlIdClean': json['urlIdClean'] == null ? undefined : json['urlIdClean'], 'lastGenDate': json['lastGenDate'] == null ? undefined : json['lastGenDate'], 'includesPastPages': json['includesPastPages'] == null ? undefined : json['includesPastPages'], 'isDemo': json['isDemo'] == null ? undefined : json['isDemo'], 'commentCount': json['commentCount'] == null ? undefined : json['commentCount'], 'isSiteAdmin': json['isSiteAdmin'] == null ? undefined : json['isSiteAdmin'], 'hasBillingIssue': json['hasBillingIssue'] == null ? undefined : json['hasBillingIssue'], 'moduleData': json['moduleData'] == null ? undefined : json['moduleData'], 'pageNumber': json['pageNumber'], 'isWhiteLabeled': json['isWhiteLabeled'] == null ? undefined : json['isWhiteLabeled'], 'isProd': json['isProd'] == null ? undefined : json['isProd'], 'isCrawler': json['isCrawler'] == null ? undefined : json['isCrawler'], 'notificationCount': json['notificationCount'] == null ? undefined : json['notificationCount'], 'hasMore': json['hasMore'] == null ? undefined : json['hasMore'], 'isClosed': json['isClosed'] == null ? undefined : json['isClosed'], 'presencePollState': json['presencePollState'] == null ? undefined : json['presencePollState'], 'customConfig': json['customConfig'] == null ? undefined : (0, CustomConfigParameters_1.CustomConfigParametersFromJSON)(json['customConfig']), 'urlIdWS': json['urlIdWS'] == null ? undefined : json['urlIdWS'], 'userIdWS': json['userIdWS'] == null ? undefined : json['userIdWS'], 'tenantIdWS': json['tenantIdWS'] == null ? undefined : json['tenantIdWS'], 'secondaryCode': json['secondaryCode'] == null ? undefined : json['secondaryCode'], 'bannedUntil': json['bannedUntil'] == null ? undefined : json['bannedUntil'], 'maxCharacterLength': json['maxCharacterLength'] == null ? undefined : json['maxCharacterLength'], 'translatedError': json['translatedError'] == null ? undefined : json['translatedError'], }; } function GetCommentsPublicResponseToJSON(json) { return GetCommentsPublicResponseToJSONTyped(json, false); } function GetCommentsPublicResponseToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'statusCode': value['statusCode'], 'status': (0, APIStatus_1.APIStatusToJSON)(value['status']), 'code': value['code'], 'reason': value['reason'], 'translatedWarning': value['translatedWarning'], 'comments': (value['comments'].map(PublicComment_1.PublicCommentToJSON)), 'user': (0, UserSessionInfo_1.UserSessionInfoToJSON)(value['user']), 'urlIdClean': value['urlIdClean'], 'lastGenDate': value['lastGenDate'], 'includesPastPages': value['includesPastPages'], 'isDemo': value['isDemo'], 'commentCount': value['commentCount'], 'isSiteAdmin': value['isSiteAdmin'], 'hasBillingIssue': value['hasBillingIssue'], 'moduleData': value['moduleData'], 'pageNumber': value['pageNumber'], 'isWhiteLabeled': value['isWhiteLabeled'], 'isProd': value['isProd'], 'isCrawler': value['isCrawler'], 'notificationCount': value['notificationCount'], 'hasMore': value['hasMore'], 'isClosed': value['isClosed'], 'presencePollState': value['presencePollState'], 'customConfig': (0, CustomConfigParameters_1.CustomConfigParametersToJSON)(value['customConfig']), 'urlIdWS': value['urlIdWS'], 'userIdWS': value['userIdWS'], 'tenantIdWS': value['tenantIdWS'], 'secondaryCode': value['secondaryCode'], 'bannedUntil': value['bannedUntil'], 'maxCharacterLength': value['maxCharacterLength'], 'translatedError': value['translatedError'], }; } //# sourceMappingURL=GetCommentsPublicResponse.js.map