import { Gauge } from "prom-client";
/**
 * Extends the prom-client Gauge to be able to add multiple collect functions after instantiation
 */
export class GaugeExtra extends Gauge {
    collectFns = [];
    addCollect(collectFn) {
        this.collectFns.push(collectFn);
    }
    /**
     * @override Metric.collect
     */
    collect() {
        for (const collectFn of this.collectFns) {
            collectFn(this);
        }
    }
}
//# sourceMappingURL=gauge.js.map