"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.GetNotebookFromWebUrlRequestBuilderRequestsMetadata = exports.GetNotebookFromWebUrlRequestBuilderUriTemplate = exports.serializeGetNotebookFromWebUrlPostRequestBody = exports.deserializeIntoGetNotebookFromWebUrlPostRequestBody = exports.createGetNotebookFromWebUrlPostRequestBodyFromDiscriminatorValue = void 0;
/* tslint:disable */
/* eslint-disable */
// Generated by Microsoft Kiota
const models_1 = require("@microsoft/msgraph-beta-sdk/models/");
const oDataErrors_1 = require("@microsoft/msgraph-beta-sdk/models/oDataErrors/");
/**
 * Creates a new instance of the appropriate class based on discriminator value
 * @param parseNode The parse node to use to read the discriminator value and create the object
 * @returns {GetNotebookFromWebUrlPostRequestBody}
 */
function createGetNotebookFromWebUrlPostRequestBodyFromDiscriminatorValue(parseNode) {
    return deserializeIntoGetNotebookFromWebUrlPostRequestBody;
}
exports.createGetNotebookFromWebUrlPostRequestBodyFromDiscriminatorValue = createGetNotebookFromWebUrlPostRequestBodyFromDiscriminatorValue;
/**
 * The deserialization information for the current model
 * @returns {Record<string, (node: ParseNode) => void>}
 */
function deserializeIntoGetNotebookFromWebUrlPostRequestBody(getNotebookFromWebUrlPostRequestBody = {}) {
    return {
        "backingStoreEnabled": n => { getNotebookFromWebUrlPostRequestBody.backingStoreEnabled = true; },
        "webUrl": n => { getNotebookFromWebUrlPostRequestBody.webUrl = n.getStringValue(); },
    };
}
exports.deserializeIntoGetNotebookFromWebUrlPostRequestBody = deserializeIntoGetNotebookFromWebUrlPostRequestBody;
/**
 * Serializes information the current object
 * @param writer Serialization writer to use to serialize this model
 */
function serializeGetNotebookFromWebUrlPostRequestBody(writer, getNotebookFromWebUrlPostRequestBody = {}) {
    writer.writeStringValue("webUrl", getNotebookFromWebUrlPostRequestBody.webUrl);
    writer.writeAdditionalData(getNotebookFromWebUrlPostRequestBody.additionalData);
}
exports.serializeGetNotebookFromWebUrlPostRequestBody = serializeGetNotebookFromWebUrlPostRequestBody;
/**
 * Uri template for the request builder.
 */
exports.GetNotebookFromWebUrlRequestBuilderUriTemplate = "{+baseurl}/users/{user%2Did}/onenote/notebooks/getNotebookFromWebUrl";
/**
 * Metadata for all the requests in the request builder.
 */
exports.GetNotebookFromWebUrlRequestBuilderRequestsMetadata = {
    post: {
        uriTemplate: exports.GetNotebookFromWebUrlRequestBuilderUriTemplate,
        responseBodyContentType: "application/json",
        errorMappings: {
            XXX: oDataErrors_1.createODataErrorFromDiscriminatorValue,
        },
        adapterMethodName: "send",
        responseBodyFactory: models_1.createCopyNotebookModelFromDiscriminatorValue,
        requestBodyContentType: "application/json",
        requestBodySerializer: serializeGetNotebookFromWebUrlPostRequestBody,
        requestInformationContentSetMethod: "setContentFromParsable",
    },
};
/* tslint:enable */
/* eslint-enable */
