UNPKG

wallee

Version:
46 lines (45 loc) 2.11 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.instanceOfSubscriptionAffiliate = instanceOfSubscriptionAffiliate; exports.SubscriptionAffiliateFromJSON = SubscriptionAffiliateFromJSON; exports.SubscriptionAffiliateFromJSONTyped = SubscriptionAffiliateFromJSONTyped; exports.SubscriptionAffiliateToJSON = SubscriptionAffiliateToJSON; exports.SubscriptionAffiliateToJSONTyped = SubscriptionAffiliateToJSONTyped; const CreationEntityState_1 = require("./CreationEntityState"); /** * Check if a given object implements the SubscriptionAffiliate interface. */ function instanceOfSubscriptionAffiliate(value) { return true; } function SubscriptionAffiliateFromJSON(json) { return SubscriptionAffiliateFromJSONTyped(json, false); } function SubscriptionAffiliateFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'reference': json['reference'] == null ? undefined : json['reference'], 'linkedSpaceId': json['linkedSpaceId'] == null ? undefined : json['linkedSpaceId'], 'metaData': json['metaData'] == null ? undefined : json['metaData'], 'name': json['name'] == null ? undefined : json['name'], 'plannedPurgeDate': json['plannedPurgeDate'] == null ? undefined : (new Date(json['plannedPurgeDate'])), 'externalId': json['externalId'] == null ? undefined : json['externalId'], 'language': json['language'] == null ? undefined : json['language'], 'id': json['id'] == null ? undefined : json['id'], 'state': json['state'] == null ? undefined : (0, CreationEntityState_1.CreationEntityStateFromJSON)(json['state']), 'version': json['version'] == null ? undefined : json['version'], }; } function SubscriptionAffiliateToJSON(json) { return SubscriptionAffiliateToJSONTyped(json, false); } function SubscriptionAffiliateToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'state': (0, CreationEntityState_1.CreationEntityStateToJSON)(value['state']), }; }