import { OnDestroy } from '@angular/core';
import { Constructor } from '@rxap/utilities';
import { Observable, OperatorFunction, TeardownLogic } from 'rxjs';
import { BaseDataSource, BaseDataSourceMetadata, BaseDataSourceViewer } from './base.data-source';
import * as i0 from "@angular/core";
export interface PipeDataSourceMetadata extends BaseDataSourceMetadata {
    /**
     * If true the parent data source will be refreshed when the pipe data source is refreshed
     * @default false
     */
    refreshParent?: boolean;
}
export declare function RxapPipeDataSource(metadata: PipeDataSourceMetadata, className?: string, packageName?: string): (target: Constructor<PipeDataSource>) => void;
export declare class PipeDataSource<Source = any, Target = Source> extends BaseDataSource<Target> implements OnDestroy {
    readonly dataSource: BaseDataSource<Source>;
    private readonly _refresh;
    constructor(dataSource: BaseDataSource<Source>, operation?: OperatorFunction<Source, any> | null, ...operations: Array<OperatorFunction<any, any> | PipeDataSourceMetadata>);
    private _operations;
    protected get operations(): Array<OperatorFunction<any, any>>;
    setOperations(operation: OperatorFunction<Source, any>, ...operations: Array<OperatorFunction<any, any>>): void;
    ngOnDestroy(): void;
    /**
     * @param parent true - call the refresh method of the parent data source
     */
    refresh(parent?: boolean): any;
    reset(): any;
    toJSON(): object;
    protected _connect(viewer: BaseDataSourceViewer): [Observable<Target>, TeardownLogic] | Observable<Target>;
    protected viewerToOperations(viewer: BaseDataSourceViewer): Array<OperatorFunction<any, any>>;
    static ɵfac: i0.ɵɵFactoryDeclaration<PipeDataSource<any, any>, [null, { optional: true; }, null]>;
    static ɵprov: i0.ɵɵInjectableDeclaration<PipeDataSource<any, any>>;
}
export declare function pipeDataSource<Source, Target>(dataSource: BaseDataSource<Source>, operation: OperatorFunction<Source, any>, ...operations: Array<OperatorFunction<any, any> | PipeDataSourceMetadata>): PipeDataSource<Source, Target>;
