"use strict";
/*!
 * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
 * Licensed under the MIT License.
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.minVersionToSharedTreeSummaryFormatVersion = exports.supportedSharedTreeSummaryFormatVersions = exports.SharedTreeSummaryFormatVersion = exports.summarizablesMetadataKey = exports.summarizablesTreeKey = void 0;
// TODO: Organize this to be adjacent to persisted types.
/**
 * The storage key for the subtree containing all summarizable indexes in the SharedTree summary.
 */
exports.summarizablesTreeKey = "indexes";
/**
 * The storage key for the blob containing metadata for the summarizable's summary.
 */
exports.summarizablesMetadataKey = ".metadata";
/**
 * The versions for the SharedTree summary format.
 */
var SharedTreeSummaryFormatVersion;
(function (SharedTreeSummaryFormatVersion) {
    /**
     * This version represents summary format before summary versioning was introduced.
     */
    SharedTreeSummaryFormatVersion[SharedTreeSummaryFormatVersion["v1"] = 1] = "v1";
    /**
     * This version adds metadata to the summary. This is backward compatible with version 1.
     */
    SharedTreeSummaryFormatVersion[SharedTreeSummaryFormatVersion["v2"] = 2] = "v2";
    /**
     * The latest version of the SharedTree summary. Must be updated when a new version is added.
     */
    SharedTreeSummaryFormatVersion[SharedTreeSummaryFormatVersion["vLatest"] = 2] = "vLatest";
})(SharedTreeSummaryFormatVersion || (exports.SharedTreeSummaryFormatVersion = SharedTreeSummaryFormatVersion = {}));
exports.supportedSharedTreeSummaryFormatVersions = new Set([
    1 /* SharedTreeSummaryFormatVersion.v1 */,
    2 /* SharedTreeSummaryFormatVersion.v2 */,
]);
/**
 * Returns the summary version to use as per the given minimum version for collab.
 */
function minVersionToSharedTreeSummaryFormatVersion(version) {
    // Currently, version 2 is written which adds metadata blob to the summary.
    return 2 /* SharedTreeSummaryFormatVersion.v2 */;
}
exports.minVersionToSharedTreeSummaryFormatVersion = minVersionToSharedTreeSummaryFormatVersion;
//# sourceMappingURL=summaryTypes.js.map