"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.RunsWorker = void 0;
const Di_1 = require("../../ioc/Di");
const VPContainerToken_1 = require("../../ioc/VPContainerToken");
const workers_1 = require("@golemio/core/dist/integration-engine/workers");
const constants_1 = require("./constants");
class RunsWorker extends workers_1.AbstractWorker {
    constructor() {
        super();
        this.name = constants_1.WORKER_NAME;
        this.registerTask = (task) => {
            super.registerTask(task);
            task.queuePrefix = this.getQueuePrefix();
        };
        // Register tasks
        this.registerTask(Di_1.VPContainer.resolve(VPContainerToken_1.VPContainerToken.SaveArrivaCityRunsToDBTask));
        this.registerTask(Di_1.VPContainer.resolve(VPContainerToken_1.VPContainerToken.ProcessRegionalBusRunMessagesTask));
        this.registerTask(Di_1.VPContainer.resolve(VPContainerToken_1.VPContainerToken.SaveTramRunsToDBTask));
        this.registerTask(Di_1.VPContainer.resolve(VPContainerToken_1.VPContainerToken.SaveBusRunsToDBTask));
        this.registerTask(Di_1.VPContainer.resolve(VPContainerToken_1.VPContainerToken.SaveMetroRunsToDBTask));
        this.registerTask(Di_1.VPContainer.resolve(VPContainerToken_1.VPContainerToken.ProcessMetroRunMessagesTask));
    }
}
exports.RunsWorker = RunsWorker;
//# sourceMappingURL=RunsWorker.js.map