export class EditorExtenders {
    constructor() {
        this.m_dictionary = {};
    }
    get items() {
        let result = [];
        for (let key in this.m_dictionary) {
            result.push(this.m_dictionary[key]);
        }
        return result;
    }
    get(id) {
        return this.m_dictionary[id];
    }
    getId(factory) {
        let result = null;
        for (let key in this.m_dictionary) {
            if (this.m_dictionary[key] === factory) {
                result = key;
                break;
            }
        }
        return result;
    }
    add(id, factory) {
        this.m_dictionary[id] = factory;
    }
}
