import { EventEmitter, OnDestroy, OnInit } from '@angular/core';
import { ModalController } from '@ionic/angular';
import { TapValueEditorContainerComponent } from '@iotize/ionic';
import { AbstractVariable } from '@iotize/tap/data';
import { KeyTypeType } from '@iotize/tap/data/lib/utility/editable-data-stream';
import { BehaviorSubject } from 'rxjs';
import { Bit, BitTemplate } from './definitions';
import * as i0 from "@angular/core";
export declare class TapVariableBitsEditorComponent implements OnInit, OnDestroy {
    private modalController;
    ctx: TapValueEditorContainerComponent;
    bitsArrayEditable: Bit[][];
    _variableChange: BehaviorSubject<AbstractVariable<number | Uint8Array, KeyTypeType> | undefined>;
    dataSuccessfullyUpdated: EventEmitter<string>;
    set variable(variable: AbstractVariable<number | Uint8Array> | undefined);
    showHelpButton: boolean;
    bitOffColor: string;
    bitOnColor: string;
    editable: boolean;
    editButtonsColor?: string;
    msb?: boolean;
    numberByteLength: 1 | 2 | 4;
    set bitsTemplate(template: BitTemplate[][] | undefined);
    set value(v: number | Uint8Array | undefined);
    private _bitsTemplate;
    private destroyed;
    loaded: boolean;
    onSaving: boolean;
    editMode: boolean;
    rawStored?: Uint8Array;
    private _infoModal?;
    constructor(modalController: ModalController);
    ngOnDestroy(): void;
    ngOnInit(): void;
    private _setRawValue;
    private rawToView;
    private _initBitsTemplate;
    cancelEdit(): void;
    onEditMode(): void;
    onClickEdit(bit: Bit): Promise<void>;
    onSaveEdit(variable: AbstractVariable<number | Uint8Array> | undefined): Promise<void>;
    private getNumberByteLength;
    private _restoreLastValueReceived;
    private _valueToBuffer;
    private _bitIndexToBufferPosition;
    private _userInputToBuffer;
    /**
     * @deprecated use numberByteLength parameter instead
     * @param variable
     * @returns
     */
    private _guessDataLength;
    showInfo(): Promise<void>;
    static ɵfac: i0.ɵɵFactoryDeclaration<TapVariableBitsEditorComponent, never>;
    static ɵcmp: i0.ɵɵComponentDeclaration<TapVariableBitsEditorComponent, "tap-variable-bits-editor", never, { "variable": "variable"; "showHelpButton": "showHelpButton"; "bitOffColor": "bitOffColor"; "bitOnColor": "bitOnColor"; "editable": "editable"; "editButtonsColor": "editButtonsColor"; "msb": "msb"; "numberByteLength": "numberByteLength"; "bitsTemplate": "bitsTemplate"; "value": "value"; }, { "dataSuccessfullyUpdated": "dataSuccessfullyUpdated"; }, never, never, false>;
}
export declare function sanitizeBitsTemplateParameter(template: BitTemplate[][] | undefined): BitTemplate[][] | undefined;
