"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.ApiLatencyWidget = void 0;
const api_latency_metric_1 = require("./api-latency-metric");
const latency_widget_1 = require("./latency-widget");
/**
 * Creates a latency widget using an API Gateway latency metric
 */
class ApiLatencyWidget extends latency_widget_1.LatencyWidget {
    constructor(props) {
        const latency = new api_latency_metric_1.ApiLatencyMetric({
            apiName: props.apiName,
            sloThreshold: props.sloThreshold,
            sloWindow: props.sloWindow,
        });
        super({ latency, ...props });
    }
}
exports.ApiLatencyWidget = ApiLatencyWidget;
