UNPKG

wallee

Version:
50 lines (49 loc) 2.65 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.instanceOfDebtCollectorConfiguration = instanceOfDebtCollectorConfiguration; exports.DebtCollectorConfigurationFromJSON = DebtCollectorConfigurationFromJSON; exports.DebtCollectorConfigurationFromJSONTyped = DebtCollectorConfigurationFromJSONTyped; exports.DebtCollectorConfigurationToJSON = DebtCollectorConfigurationToJSON; exports.DebtCollectorConfigurationToJSONTyped = DebtCollectorConfigurationToJSONTyped; const DebtCollector_1 = require("./DebtCollector"); const CreationEntityState_1 = require("./CreationEntityState"); const DebtCollectorCondition_1 = require("./DebtCollectorCondition"); /** * Check if a given object implements the DebtCollectorConfiguration interface. */ function instanceOfDebtCollectorConfiguration(value) { return true; } function DebtCollectorConfigurationFromJSON(json) { return DebtCollectorConfigurationFromJSONTyped(json, false); } function DebtCollectorConfigurationFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'linkedSpaceId': json['linkedSpaceId'] == null ? undefined : json['linkedSpaceId'], 'skipReviewEnabled': json['skipReviewEnabled'] == null ? undefined : json['skipReviewEnabled'], 'name': json['name'] == null ? undefined : json['name'], 'plannedPurgeDate': json['plannedPurgeDate'] == null ? undefined : (new Date(json['plannedPurgeDate'])), 'enabledSpaceViews': json['enabledSpaceViews'] == null ? undefined : new Set(json['enabledSpaceViews']), 'id': json['id'] == null ? undefined : json['id'], 'state': json['state'] == null ? undefined : (0, CreationEntityState_1.CreationEntityStateFromJSON)(json['state']), 'conditions': json['conditions'] == null ? undefined : (json['conditions'].map(DebtCollectorCondition_1.DebtCollectorConditionFromJSON)), 'priority': json['priority'] == null ? undefined : json['priority'], 'version': json['version'] == null ? undefined : json['version'], 'collector': json['collector'] == null ? undefined : (0, DebtCollector_1.DebtCollectorFromJSON)(json['collector']), }; } function DebtCollectorConfigurationToJSON(json) { return DebtCollectorConfigurationToJSONTyped(json, false); } function DebtCollectorConfigurationToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'state': (0, CreationEntityState_1.CreationEntityStateToJSON)(value['state']), 'collector': (0, DebtCollector_1.DebtCollectorToJSON)(value['collector']), }; }