import { ChangeDetectorRef, EventEmitter, OnDestroy, OnInit, TemplateRef } from '@angular/core';
import { LoadingController } from '@ionic/angular';
import { DeviceScanner } from '@iotize/tap/scanner/api';
import { ProtocolSelectedEvent } from '../api';
import { DiscoveredDeviceType } from './definitions';
import * as i0 from "@angular/core";
/**
 * Scanner for bluetooth
 */
export declare class TapScannerBleComponent implements OnInit, OnDestroy {
    tapScanner: DeviceScanner<DiscoveredDeviceType>;
    changeDetector: ChangeDetectorRef;
    loadingCtrl: LoadingController;
    /**
     * Scan result template to use to display scan results.
     *
     * If not provided, it will use a default component to display devices.
     *
     * @example
     * <!-- Display devices with tap-ble-scan-result component -->
     * <tap-scanner-ble [scanResultsTemplate]="scanResultsTemplate">
     *    <ng-template #scanResultsTemplate let-devices>
     *        <tap-ble-scan-result [devices]="devices" [showSignalStrenght]="false"></tap-ble-scan-result>
     *    </ng-template>
     * </tap-scanner-ble>
     *
     */
    scanResultsTemplate?: TemplateRef<any>;
    /**
     * @deprecated Not used anymore. start/stop buttons must be define by user
     */
    showScanButton: boolean;
    /**
     * RSSI update threshold.
     * If device list is the same, we will only emit a device update event
     * if the Math.abs(previousRSSI - newRSSI) >= rssiUpdateThreshold
     */
    rssiUpdateThreshold: number;
    /**
     * Event emitted when a scan result has been selected
     * @deprecated see protocolSelected
     */
    onProtocolSelected: EventEmitter<ProtocolSelectedEvent>;
    /**
     * Event emitted when a scan result has been selected
     */
    protocolSelected: EventEmitter<ProtocolSelectedEvent>;
    /**
     * Event emitted when an error occurs
     */
    onError: EventEmitter<Error>;
    results: DiscoveredDeviceType[];
    private readonly destroyed;
    isScanning: boolean;
    constructor(tapScanner: DeviceScanner<DiscoveredDeviceType>, changeDetector: ChangeDetectorRef, loadingCtrl: LoadingController);
    ngOnInit(): void;
    notifyError(error: any): void;
    ngOnDestroy(): void;
    onItemClicked(device: DiscoveredDeviceType): void;
    startScan(): void;
    stopScan(): void;
    private mergeScanResults;
    private addOrRefreshScanResultList;
    static ɵfac: i0.ɵɵFactoryDeclaration<TapScannerBleComponent, never>;
    static ɵcmp: i0.ɵɵComponentDeclaration<TapScannerBleComponent, "tap-scanner-ble", never, { "scanResultsTemplate": "scanResultsTemplate"; "showScanButton": "showScanButton"; "rssiUpdateThreshold": "rssiUpdateThreshold"; }, { "onProtocolSelected": "onProtocolSelected"; "protocolSelected": "protocolSelected"; "onError": "onError"; }, never, never>;
}
