export class Registry {
    items = new Map();
    register(id, item) {
        this.items.set(id, item);
    }
    get(id) {
        return this.items.get(id);
    }
    has(id) {
        return this.items.has(id);
    }
    getAll() {
        return Array.from(this.items.values());
    }
    listIds() {
        return Array.from(this.items.keys());
    }
    unregister(id) {
        return this.items.delete(id);
    }
    clear() {
        this.items.clear();
    }
    size() {
        return this.items.size;
    }
}
//# sourceMappingURL=Registry.js.map