"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const Unit_1 = require("../../../../Class/Unit");
const _ids_1 = require("../../../_ids");
class Global extends Unit_1.Unit {
    constructor(system) {
        super({
            i: [],
            o: [],
        }, {}, system, _ids_1.ID_GLOBAL);
    }
    subscribe(path, key, listener) {
        return this.__system.global.data.subscribe(path, key, listener);
    }
    get(name) {
        return this.__system.global.data.get(name);
    }
    set(name, data) {
        return this.__system.global.data.set(name, data);
    }
    delete(name) {
        return this.__system.global.data.delete(name);
    }
    deepSet(path, data) {
        return this.__system.global.data.deepSet(path, data);
    }
    deepGet(path) {
        return this.__system.global.data.deepGet(path);
    }
    deepDelete(path) {
        return this.__system.global.data.deepDelete(path);
    }
    deepHas(path) {
        try {
            this.deepGet(path);
            return true;
        }
        catch (err) {
            return false;
        }
    }
    keys() {
        return this.__system.global.data.keys();
    }
    hasKey(name) {
        return this.__system.global.data.hasKey(name);
    }
}
exports.default = Global;
//# sourceMappingURL=index.js.map