import { AbstractType, InjectionToken, Injector, Type } from '@angular/core';
import { BaseDefinition, BaseDefinitionMetadata } from '@rxap/definition';
import { Subject } from 'rxjs';
import { Refreshable } from '@rxap/utilities';
import { CounterSubject } from '@rxap/rxjs';
import * as i0 from "@angular/core";
export interface BaseRemoteMethodMetadata extends BaseDefinitionMetadata {
    refresh?: Array<Type<Refreshable> | InjectionToken<Refreshable> | AbstractType<Refreshable>>;
}
export declare function RxapRemoteMethod<MetaData extends BaseDefinitionMetadata = BaseDefinitionMetadata>(metadataOrId: MetaData | string, className?: string, packageName?: string): (target: any) => void;
export declare abstract class BaseRemoteMethod<ReturnType = any, Parameter = any, Metadata extends BaseRemoteMethodMetadata = BaseRemoteMethodMetadata> extends BaseDefinition<Metadata> {
    executed$: Subject<ReturnType>;
    executionsInProgress$: CounterSubject;
    readonly injector: Injector;
    private _pauseRefresh;
    constructor(injector?: Injector | null, metaData?: any | null);
    call(parameters?: Parameter): Promise<ReturnType>;
    executed(result: ReturnType): void;
    pauseRefresh(): void;
    resumeRefresh(): void;
    refresh(): void;
    protected abstract _call(parameters?: Parameter): Promise<ReturnType> | ReturnType;
    static ɵfac: i0.ɵɵFactoryDeclaration<BaseRemoteMethod<any, any, any>, [{ optional: true; }, { optional: true; }]>;
    static ɵprov: i0.ɵɵInjectableDeclaration<BaseRemoteMethod<any, any, any>>;
}
