import { AxisMap } from './axis-map.js';
export class SheetAxisMap {
    rows;
    columns;
    constructor() {
        this.rows = new AxisMap();
        this.columns = new AxisMap();
    }
    get(axis) {
        return axis === 'row' ? this.rows : this.columns;
    }
    getId(axis, index) {
        return this.get(axis).getId(index);
    }
    setId(axis, index, id) {
        this.get(axis).setId(index, id);
    }
    ensureId(axis, index, createId) {
        return this.get(axis).ensureId(index, createId);
    }
    ensureDenseIds(axis, start, count, createId) {
        return this.get(axis).ensureDenseIds(start, count, createId);
    }
    ensureDenseIdsFrom(axis, start, count, createIds) {
        return this.get(axis).ensureDenseIdsFrom(start, count, createIds);
    }
    indexOf(axis, id) {
        return this.get(axis).indexOf(id);
    }
    list(axis) {
        return this.get(axis).list();
    }
    snapshot(axis, start, count) {
        return this.get(axis).snapshot(start, count);
    }
    replaceRange(axis, start, entries) {
        this.get(axis).replaceRange(start, entries);
    }
    splice(axis, start, deleteCount, insertCountOrEntries, maybeEntries) {
        if (typeof insertCountOrEntries === 'number') {
            return this.get(axis).splice(start, deleteCount, insertCountOrEntries, maybeEntries ?? []);
        }
        return this.get(axis).splice(start, deleteCount, insertCountOrEntries);
    }
    move(axis, start, count, target) {
        this.get(axis).move(start, count, target);
    }
}
//# sourceMappingURL=sheet-axis-map.js.map