import { DestroyRef } from '@angular/core';
import { QdTreeDataRow } from '../model/tree-data.interface';
import { QdTreeRowsService } from './tree-rows.service';
import * as i0 from "@angular/core";
/**
 * The **QdTreeRowExpanderService** allows you to expand certain rows by conditions and close all rows.
 *
 * **Expand rows**
 * To expand rows, simply inject the QdTreeRowExpanderService and use expandAll or expandWithCondition depending on yourneeds.
 * For both you need to provide the QdTree's that should be expanded:
 *
 * ```ts
 * treeRowExpanderService.expandWithCondition("my-tree-id", (row) => row.category === 'delivery');
 * ```
 *
 * Additionally you can also expand rows by data that is not shown in the tree but available in your provided data in QdTree. For this
 * simply use the second argument of the expression and determine on that:
 *
 * ```ts
 * treeRowExpanderService.expandWithCondition("my-tree-id", (row, record) => record.hiddenId = "12");
 * ```
 *
 * Please be aware that a record will only be provided for the rows that are leafs / have no children.
 */
export declare class QdTreeRowExpanderService<T extends string> {
    trees: Map<string, {
        treeRows: QdTreeDataRow<T>[];
        rowService: QdTreeRowsService<T>;
    }>;
    destroyRef: DestroyRef;
    init(treeId: string, rowService: QdTreeRowsService<T>): void;
    /**
     * Expands all rows.
     * @param treeId The QdTree's ID
     */
    expandAll(treeId: string): void;
    /**
     * Closes all rows.
     * @param treeId The QdTree's ID
     */
    closeAll(treeId: string): void;
    /**
     * Expands rows by certain condition.
     * @param treeId The QdTree's ID
     * @param condition Condition that matches the rows to expand
     */
    expandWithCondition(treeId: string, condition: (row: QdTreeDataRow<T>, record?: QdTreeDataRow<T>) => boolean): void;
    private expand;
    private close;
    private traverseAndExpand;
    static ɵfac: i0.ɵɵFactoryDeclaration<QdTreeRowExpanderService<any>, never>;
    static ɵprov: i0.ɵɵInjectableDeclaration<QdTreeRowExpanderService<any>>;
}
//# sourceMappingURL=row-expander.service.d.ts.map