/* tslint:disable */
/* eslint-disable */
// Generated by Microsoft Kiota
// @ts-ignore
import { createConvertIdResultFromDiscriminatorValue, deserializeIntoBaseCollectionPaginationCountResponse, ExchangeIdFormatObject, serializeBaseCollectionPaginationCountResponse, serializeConvertIdResult } from '@microsoft/msgraph-beta-sdk/models/index.js';
// @ts-ignore
import { createODataErrorFromDiscriminatorValue } from '@microsoft/msgraph-beta-sdk/models/oDataErrors/index.js';
/**
 * 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 {TranslateExchangeIdsPostRequestBody}
 */
// @ts-ignore
export function createTranslateExchangeIdsPostRequestBodyFromDiscriminatorValue(parseNode) {
    return deserializeIntoTranslateExchangeIdsPostRequestBody;
}
/**
 * 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 {TranslateExchangeIdsPostResponse}
 */
// @ts-ignore
export function createTranslateExchangeIdsPostResponseFromDiscriminatorValue(parseNode) {
    return deserializeIntoTranslateExchangeIdsPostResponse;
}
/**
 * The deserialization information for the current model
 * @returns {Record<string, (node: ParseNode) => void>}
 */
// @ts-ignore
export function deserializeIntoTranslateExchangeIdsPostRequestBody(translateExchangeIdsPostRequestBody = {}) {
    return {
        "backingStoreEnabled": n => { translateExchangeIdsPostRequestBody.backingStoreEnabled = true; },
        "InputIds": n => { translateExchangeIdsPostRequestBody.inputIds = n.getCollectionOfPrimitiveValues(); },
        "SourceIdType": n => { translateExchangeIdsPostRequestBody.sourceIdType = n.getEnumValue(ExchangeIdFormatObject); },
        "TargetIdType": n => { translateExchangeIdsPostRequestBody.targetIdType = n.getEnumValue(ExchangeIdFormatObject); },
    };
}
/**
 * The deserialization information for the current model
 * @returns {Record<string, (node: ParseNode) => void>}
 */
// @ts-ignore
export function deserializeIntoTranslateExchangeIdsPostResponse(translateExchangeIdsPostResponse = {}) {
    return Object.assign(Object.assign({}, deserializeIntoBaseCollectionPaginationCountResponse(translateExchangeIdsPostResponse)), { "value": n => { translateExchangeIdsPostResponse.value = n.getCollectionOfObjectValues(createConvertIdResultFromDiscriminatorValue); } });
}
/**
 * Serializes information the current object
 * @param writer Serialization writer to use to serialize this model
 */
// @ts-ignore
export function serializeTranslateExchangeIdsPostRequestBody(writer, translateExchangeIdsPostRequestBody = {}) {
    if (translateExchangeIdsPostRequestBody) {
        writer.writeCollectionOfPrimitiveValues("InputIds", translateExchangeIdsPostRequestBody.inputIds);
        writer.writeEnumValue("SourceIdType", translateExchangeIdsPostRequestBody.sourceIdType);
        writer.writeEnumValue("TargetIdType", translateExchangeIdsPostRequestBody.targetIdType);
        writer.writeAdditionalData(translateExchangeIdsPostRequestBody.additionalData);
    }
}
/**
 * Serializes information the current object
 * @param writer Serialization writer to use to serialize this model
 */
// @ts-ignore
export function serializeTranslateExchangeIdsPostResponse(writer, translateExchangeIdsPostResponse = {}) {
    if (translateExchangeIdsPostResponse) {
        serializeBaseCollectionPaginationCountResponse(writer, translateExchangeIdsPostResponse);
        writer.writeCollectionOfObjectValues("value", translateExchangeIdsPostResponse.value, serializeConvertIdResult);
    }
}
/**
 * Uri template for the request builder.
 */
export const TranslateExchangeIdsRequestBuilderUriTemplate = "{+baseurl}/users/{user%2Did}/translateExchangeIds";
/**
 * Metadata for all the requests in the request builder.
 */
export const TranslateExchangeIdsRequestBuilderRequestsMetadata = {
    post: {
        uriTemplate: TranslateExchangeIdsRequestBuilderUriTemplate,
        responseBodyContentType: "application/json",
        errorMappings: {
            XXX: createODataErrorFromDiscriminatorValue,
        },
        adapterMethodName: "send",
        responseBodyFactory: createTranslateExchangeIdsPostResponseFromDiscriminatorValue,
        requestBodyContentType: "application/json",
        requestBodySerializer: serializeTranslateExchangeIdsPostRequestBody,
        requestInformationContentSetMethod: "setContentFromParsable",
    },
};
/* tslint:enable */
/* eslint-enable */
//# sourceMappingURL=index.js.map