"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.serializeSignRequestSignerInputNumberWithCommaValidationValidationTypeField = serializeSignRequestSignerInputNumberWithCommaValidationValidationTypeField;
exports.deserializeSignRequestSignerInputNumberWithCommaValidationValidationTypeField = deserializeSignRequestSignerInputNumberWithCommaValidationValidationTypeField;
exports.serializeSignRequestSignerInputNumberWithCommaValidation = serializeSignRequestSignerInputNumberWithCommaValidation;
exports.deserializeSignRequestSignerInputNumberWithCommaValidation = deserializeSignRequestSignerInputNumberWithCommaValidation;
const errors_1 = require("../box/errors");
const json_1 = require("../serialization/json");
const json_2 = require("../serialization/json");
function serializeSignRequestSignerInputNumberWithCommaValidationValidationTypeField(val) {
    return val;
}
function deserializeSignRequestSignerInputNumberWithCommaValidationValidationTypeField(val) {
    if (val == 'number_with_comma') {
        return val;
    }
    if ((0, json_1.sdIsString)(val)) {
        return val;
    }
    throw new errors_1.BoxSdkError({
        message: "Can't deserialize SignRequestSignerInputNumberWithCommaValidationValidationTypeField",
    });
}
function serializeSignRequestSignerInputNumberWithCommaValidation(val) {
    return {
        ['validation_type']: val.validationType == void 0
            ? val.validationType
            : serializeSignRequestSignerInputNumberWithCommaValidationValidationTypeField(val.validationType),
    };
}
function deserializeSignRequestSignerInputNumberWithCommaValidation(val) {
    if (!(0, json_2.sdIsMap)(val)) {
        throw new errors_1.BoxSdkError({
            message: 'Expecting a map for "SignRequestSignerInputNumberWithCommaValidation"',
        });
    }
    const validationType = val.validation_type == void 0
        ? void 0
        : deserializeSignRequestSignerInputNumberWithCommaValidationValidationTypeField(val.validation_type);
    return {
        validationType: validationType,
    };
}
//# sourceMappingURL=signRequestSignerInputNumberWithCommaValidation.js.map