"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.serializeRetentionPolicyMaxExtensionLengthResponseEnum = serializeRetentionPolicyMaxExtensionLengthResponseEnum;
exports.deserializeRetentionPolicyMaxExtensionLengthResponseEnum = deserializeRetentionPolicyMaxExtensionLengthResponseEnum;
exports.serializeRetentionPolicyMaxExtensionLengthResponse = serializeRetentionPolicyMaxExtensionLengthResponse;
exports.deserializeRetentionPolicyMaxExtensionLengthResponse = deserializeRetentionPolicyMaxExtensionLengthResponse;
const errors_1 = require("../box/errors.js");
const json_1 = require("../serialization/json.js");
function serializeRetentionPolicyMaxExtensionLengthResponseEnum(val) {
    return val;
}
function deserializeRetentionPolicyMaxExtensionLengthResponseEnum(val) {
    if (val == 'none') {
        return val;
    }
    if ((0, json_1.sdIsString)(val)) {
        return val;
    }
    throw new errors_1.BoxSdkError({
        message: "Can't deserialize RetentionPolicyMaxExtensionLengthResponseEnum",
    });
}
function serializeRetentionPolicyMaxExtensionLengthResponse(val) {
    if ((0, json_1.sdIsString)(val)) {
        return val;
    }
    try {
        return serializeRetentionPolicyMaxExtensionLengthResponseEnum(val);
    }
    catch (error) {
        void 0;
    }
    finally {
    }
    throw new errors_1.BoxSdkError({
        message: "Can't serialize RetentionPolicyMaxExtensionLengthResponse",
    });
}
function deserializeRetentionPolicyMaxExtensionLengthResponse(val) {
    if ((0, json_1.sdIsString)(val)) {
        return val;
    }
    try {
        return deserializeRetentionPolicyMaxExtensionLengthResponseEnum(val);
    }
    catch (error) {
        void 0;
    }
    finally {
    }
    throw new errors_1.BoxSdkError({
        message: "Can't deserialize RetentionPolicyMaxExtensionLengthResponse",
    });
}
//# sourceMappingURL=retentionPolicyMaxExtensionLengthResponse.js.map