umbraco-management-api-client
Version:
TypeScript client for the Umbraco Management API (auto-generated by OpenAPI Generator)
58 lines (57 loc) • 2.31 kB
JavaScript
;
/* tslint:disable */
/* eslint-disable */
/**
* Umbraco Management API
* This shows all APIs available in this version of Umbraco - including all the legacy apis that are available for backward compatibility
*
* The version of the OpenAPI document: Latest
*
*
* 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.instanceOfCopyDocumentRequestModel = instanceOfCopyDocumentRequestModel;
exports.CopyDocumentRequestModelFromJSON = CopyDocumentRequestModelFromJSON;
exports.CopyDocumentRequestModelFromJSONTyped = CopyDocumentRequestModelFromJSONTyped;
exports.CopyDocumentRequestModelToJSON = CopyDocumentRequestModelToJSON;
exports.CopyDocumentRequestModelToJSONTyped = CopyDocumentRequestModelToJSONTyped;
const ReferenceByIdModel_1 = require("./ReferenceByIdModel");
/**
* Check if a given object implements the CopyDocumentRequestModel interface.
*/
function instanceOfCopyDocumentRequestModel(value) {
if (!('relateToOriginal' in value) || value['relateToOriginal'] === undefined)
return false;
if (!('includeDescendants' in value) || value['includeDescendants'] === undefined)
return false;
return true;
}
function CopyDocumentRequestModelFromJSON(json) {
return CopyDocumentRequestModelFromJSONTyped(json, false);
}
function CopyDocumentRequestModelFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'target': json['target'] == null ? undefined : (0, ReferenceByIdModel_1.ReferenceByIdModelFromJSON)(json['target']),
'relateToOriginal': json['relateToOriginal'],
'includeDescendants': json['includeDescendants'],
};
}
function CopyDocumentRequestModelToJSON(json) {
return CopyDocumentRequestModelToJSONTyped(json, false);
}
function CopyDocumentRequestModelToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'target': (0, ReferenceByIdModel_1.ReferenceByIdModelToJSON)(value['target']),
'relateToOriginal': value['relateToOriginal'],
'includeDescendants': value['includeDescendants'],
};
}