"use strict";
// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.
// See LICENSE in the project root for license information.
Object.defineProperty(exports, "__esModule", { value: true });
exports.TERMINAL_STATUSES = exports.OperationStatus = void 0;
/**
 * Enumeration defining potential states of an operation
 * @beta
 */
var OperationStatus;
(function (OperationStatus) {
    /**
     * The Operation is ready to execute. All its dependencies have succeeded.
     */
    OperationStatus["Ready"] = "READY";
    /**
     * The Operation is waiting for one or more dependencies to complete.
     */
    OperationStatus["Waiting"] = "WAITING";
    /**
     * The Operation is Queued
     */
    OperationStatus["Queued"] = "QUEUED";
    /**
     * The Operation is currently executing
     */
    OperationStatus["Executing"] = "EXECUTING";
    /**
     * The Operation completed successfully and did not write to standard output
     */
    OperationStatus["Success"] = "SUCCESS";
    /**
     * The Operation completed successfully, but wrote to standard output
     */
    OperationStatus["SuccessWithWarning"] = "SUCCESS WITH WARNINGS";
    /**
     * The Operation was skipped via the legacy incremental build logic
     */
    OperationStatus["Skipped"] = "SKIPPED";
    /**
     * The Operation had its outputs restored from the build cache
     */
    OperationStatus["FromCache"] = "FROM CACHE";
    /**
     * The Operation failed
     */
    OperationStatus["Failure"] = "FAILURE";
    /**
     * The Operation could not be executed because one or more of its dependencies failed
     */
    OperationStatus["Blocked"] = "BLOCKED";
    /**
     * The Operation was a no-op (for example, it had an empty script)
     */
    OperationStatus["NoOp"] = "NO OP";
    /**
     * The Operation was aborted before it could execute.
     */
    OperationStatus["Aborted"] = "ABORTED";
})(OperationStatus || (exports.OperationStatus = OperationStatus = {}));
/**
 * The set of statuses that are considered terminal.
 * @alpha
 */
exports.TERMINAL_STATUSES = new Set([
    OperationStatus.Success,
    OperationStatus.SuccessWithWarning,
    OperationStatus.Skipped,
    OperationStatus.Blocked,
    OperationStatus.FromCache,
    OperationStatus.Failure,
    OperationStatus.NoOp,
    OperationStatus.Aborted
]);
//# sourceMappingURL=OperationStatus.js.map