"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getSessionManager = getSessionManager;
exports.setSessionManager = setSessionManager;
exports.getJobScheduler = getJobScheduler;
exports.setJobScheduler = setJobScheduler;
const session_manager_1 = require("./session-manager");
const smKey = "__cockpit_session_manager__";
const jsKey = "__cockpit_job_scheduler__";
function getSessionManager() {
    const g = globalThis;
    if (!g[smKey]) {
        g[smKey] = new session_manager_1.SessionManager();
    }
    return g[smKey];
}
function setSessionManager(manager) {
    globalThis[smKey] = manager;
}
function getJobScheduler() {
    return globalThis[jsKey] || null;
}
function setJobScheduler(scheduler) {
    globalThis[jsKey] = scheduler;
}
