import * as _c8y_client from '@c8y/client';
import { IManagedObject, IOperation, InventoryService, IResultList } from '@c8y/client';
import { ActivatedRoute, Router } from '@angular/router';
import { GainsightService, AlertService, PickedFiles, ValidationPattern, ModalService, Column, ActionControl, ServerSideDataCallback, DataGridService, DataSourceModifier, ServerSideDataResult } from '@c8y/ngx-components';
import * as i1 from '@c8y/ngx-components/repository/shared';
import { DeviceFirmware, RepositoryService, FilterCriteria, RepositoryCategory, ModalModel, FirmwareBinary } from '@c8y/ngx-components/repository/shared';
import { BsModalService, BsModalRef } from 'ngx-bootstrap/modal';
import * as rxjs from 'rxjs';
import { BehaviorSubject, Observable, Subject } from 'rxjs';
import * as i0 from '@angular/core';
import { ModuleWithProviders, EventEmitter, OnInit, OnDestroy } from '@angular/core';
import * as i2 from '@c8y/ngx-components/operations/operation-details';
import { NgForm } from '@angular/forms';
import { BsDropdownDirective } from 'ngx-bootstrap/dropdown';
import { TranslateService } from '@ngx-translate/core';

declare class FirmwareDeviceTabComponent {
    private route;
    private repository;
    private inventory;
    private bsModal;
    private gainsightService;
    PRODUCT_EXPERIENCE: {
        readonly SOFTWARE: {
            readonly EVENTS: {
                readonly REPOSITORY: "softwareRepository";
                readonly DEVICE_TAB: "deviceSoftware";
            };
            readonly COMPONENTS: {
                readonly ADD_SOFTWARE_MODAL: "add-software-modal";
                readonly DEVICE_SOFTWARE_CHANGES: "device-software-changes";
                readonly DEVICE_SOFTWARE_LIST: "device-software-list";
            };
            readonly ACTIONS: {
                readonly APPLY_SOFTWARE_CHANGES: "applySoftwareChanges";
                readonly CLEAR_SOFTWARE_CHANGES: "clearSoftwareChanges";
                readonly OPEN_INSTALL_SOFTWARE: "openInstallSoftwareModal";
                readonly OPEN_UPDATE_SOFTWARE: "openUpdateSoftwareModal";
                readonly DELETE_SOFTWARE: "deleteSoftware";
            };
            readonly RESULTS: {
                readonly ADD_SOFTWARE: "addSoftware";
                readonly ADD_SOFTWARE_VERSION: "addSoftwareVersion";
                readonly EDIT_SOFTWARE: "editSoftware";
            };
        };
        readonly FIRMWARE: {
            readonly EVENTS: {
                readonly REPOSITORY: "firmwareRepository";
                readonly DEVICE_TAB: "deviceFirmware";
            };
            readonly COMPONENTS: {
                readonly ADD_FIRMWARE_MODAL: "add-firmware-modal";
                readonly ADD_FIRMWAR_PATCH_MODAL: "add-firmware-patch-modal";
                readonly FIRMWARE_DEVICE_TAB: "firmware-device-tab";
                readonly DEVICE_FIRMWARE_LIST: "device-firmware-list";
            };
            readonly ACTIONS: {
                readonly OPEN_INSTALL_FIRMWARE_DIALOG: "openInstallFirmwareDialog";
                readonly OPEN_REPLACE_FIRMWARE_DIALOG: "openReplaceFirmwareDialog";
                readonly OPEN_INSTALL_FIRMWARE_PATCH_DIALOG: "openInstallFirmwarePatchDialog";
            };
            readonly RESULTS: {
                readonly ADD_FIRMWARE: "addFirmware";
                readonly ADD_FIRMWARE_VERSION: "addFirmwareVersion";
                readonly ADD_FIRMWARE_PATCH: "addFirmwarePatch";
                readonly EDIT_FIRMWARE: "editFirmware";
                readonly CREATE_FIRMWARE_UPDATE_OPERATION: "createFirmwareUpdateOperation";
            };
        };
        readonly SHARED: {
            readonly COMPONENTS: {
                readonly REPOSITORY_SELECT_MODAL: "repository-select-modal";
                readonly SELECT_CONFIGURATION_MODAL: "select-configuration-modal";
            };
        };
    };
    isEmpty: any;
    reloading: boolean;
    device$: BehaviorSubject<IManagedObject>;
    deviceFirmwareFragment$: Observable<DeviceFirmware>;
    firmwareBinary$: Observable<IManagedObject>;
    repositoryEntry$: Observable<IManagedObject>;
    patches$: Observable<IManagedObject[]>;
    supportsFirmwareOperations$: Observable<boolean>;
    changesOperation$: BehaviorSubject<IOperation>;
    changesInProgress$: Observable<boolean>;
    constructor(route: ActivatedRoute, repository: RepositoryService, inventory: InventoryService, bsModal: BsModalService, gainsightService: GainsightService);
    ngOnInit(): Promise<void>;
    installFirmware(): void;
    getRepositoryEntriesWithVersions$(searchTerm$: BehaviorSubject<FilterCriteria>): Observable<IManagedObject[]>;
    getAndAssignRepositoryBinaries(mos: IManagedObject[]): IManagedObject[];
    addPatch(): void;
    getRepositoryEntryWithPatches$(): Observable<{
        versions: IManagedObject[];
        creationTime: string;
        id: string;
        lastUpdated: string;
        owner: string;
        self: string;
        additionParents: _c8y_client.IManagedObjectReferences;
        assetParents: _c8y_client.IManagedObjectReferences;
        childAdditions: _c8y_client.IManagedObjectReferences;
        childAssets: _c8y_client.IManagedObjectReferences;
        childDevices: _c8y_client.IManagedObjectReferences;
        deviceParents: _c8y_client.IManagedObjectReferences;
    }[]>;
    loadDevice(): Promise<void>;
    private handleOperation;
    private loadOperation;
    private trackOperation;
    private isInProgress;
    static ɵfac: i0.ɵɵFactoryDeclaration<FirmwareDeviceTabComponent, never>;
    static ɵcmp: i0.ɵɵComponentDeclaration<FirmwareDeviceTabComponent, "c8y-firmware-device-tab", never, {}, {}, never, never, true, never>;
}

declare class FirmwareDeviceTabGuard {
    canActivate(route: any): any;
    static ɵfac: i0.ɵɵFactoryDeclaration<FirmwareDeviceTabGuard, never>;
    static ɵprov: i0.ɵɵInjectableDeclaration<FirmwareDeviceTabGuard>;
}

declare class FirmwareRepositoryDeviceTabModule {
    static forRoot(): ModuleWithProviders<FirmwareRepositoryDeviceTabModule>;
    static ɵfac: i0.ɵɵFactoryDeclaration<FirmwareRepositoryDeviceTabModule, never>;
    static ɵmod: i0.ɵɵNgModuleDeclaration<FirmwareRepositoryDeviceTabModule, never, [typeof i1.SharedRepositoryModule, typeof i2.OperationDetailsModule, typeof FirmwareDeviceTabComponent], never>;
    static ɵinj: i0.ɵɵInjectorDeclaration<FirmwareRepositoryDeviceTabModule>;
}

declare class AddFirmwarePatchModalComponent {
    private modal;
    private repository;
    private alert;
    PRODUCT_EXPERIENCE: {
        readonly SOFTWARE: {
            readonly EVENTS: {
                readonly REPOSITORY: "softwareRepository";
                readonly DEVICE_TAB: "deviceSoftware";
            };
            readonly COMPONENTS: {
                readonly ADD_SOFTWARE_MODAL: "add-software-modal";
                readonly DEVICE_SOFTWARE_CHANGES: "device-software-changes";
                readonly DEVICE_SOFTWARE_LIST: "device-software-list";
            };
            readonly ACTIONS: {
                readonly APPLY_SOFTWARE_CHANGES: "applySoftwareChanges";
                readonly CLEAR_SOFTWARE_CHANGES: "clearSoftwareChanges";
                readonly OPEN_INSTALL_SOFTWARE: "openInstallSoftwareModal";
                readonly OPEN_UPDATE_SOFTWARE: "openUpdateSoftwareModal";
                readonly DELETE_SOFTWARE: "deleteSoftware";
            };
            readonly RESULTS: {
                readonly ADD_SOFTWARE: "addSoftware";
                readonly ADD_SOFTWARE_VERSION: "addSoftwareVersion";
                readonly EDIT_SOFTWARE: "editSoftware";
            };
        };
        readonly FIRMWARE: {
            readonly EVENTS: {
                readonly REPOSITORY: "firmwareRepository";
                readonly DEVICE_TAB: "deviceFirmware";
            };
            readonly COMPONENTS: {
                readonly ADD_FIRMWARE_MODAL: "add-firmware-modal";
                readonly ADD_FIRMWAR_PATCH_MODAL: "add-firmware-patch-modal";
                readonly FIRMWARE_DEVICE_TAB: "firmware-device-tab";
                readonly DEVICE_FIRMWARE_LIST: "device-firmware-list";
            };
            readonly ACTIONS: {
                readonly OPEN_INSTALL_FIRMWARE_DIALOG: "openInstallFirmwareDialog";
                readonly OPEN_REPLACE_FIRMWARE_DIALOG: "openReplaceFirmwareDialog";
                readonly OPEN_INSTALL_FIRMWARE_PATCH_DIALOG: "openInstallFirmwarePatchDialog";
            };
            readonly RESULTS: {
                readonly ADD_FIRMWARE: "addFirmware";
                readonly ADD_FIRMWARE_VERSION: "addFirmwareVersion";
                readonly ADD_FIRMWARE_PATCH: "addFirmwarePatch";
                readonly EDIT_FIRMWARE: "editFirmware";
                readonly CREATE_FIRMWARE_UPDATE_OPERATION: "createFirmwareUpdateOperation";
            };
        };
        readonly SHARED: {
            readonly COMPONENTS: {
                readonly REPOSITORY_SELECT_MODAL: "repository-select-modal";
                readonly SELECT_CONFIGURATION_MODAL: "select-configuration-modal";
            };
        };
    };
    saved: EventEmitter<RepositoryCategory>;
    dropdown: BsDropdownDirective;
    form: NgForm;
    textForFirmwareUrlPopover: string;
    model: ModalModel;
    firmwareInput$: BehaviorSubject<string>;
    firmwares$: Observable<IResultList<IManagedObject>>;
    firmwareSelected$: BehaviorSubject<Partial<RepositoryCategory>>;
    patchDependencyInput$: BehaviorSubject<string>;
    saving: boolean;
    firmwarePreselected: boolean;
    baseVersions$: Observable<IResultList<IManagedObject>>;
    baseVersionsFilterPipe: rxjs.UnaryFunction<Observable<[]>, Observable<never[]>>;
    constructor(modal: BsModalRef, repository: RepositoryService, alert: AlertService);
    ngOnInit(): Promise<void>;
    setInitialState(): void;
    save(): Promise<void>;
    successMsg(): void;
    cancel(): void;
    onFile(dropped: PickedFiles): void;
    static ɵfac: i0.ɵɵFactoryDeclaration<AddFirmwarePatchModalComponent, never>;
    static ɵcmp: i0.ɵɵComponentDeclaration<AddFirmwarePatchModalComponent, "c8y-add-firmware-patch-modal.component", never, {}, { "saved": "saved"; }, never, never, true, never>;
}

declare class AddFirmwareModalComponent {
    private modal;
    private repositoryService;
    private alert;
    PRODUCT_EXPERIENCE: {
        readonly SOFTWARE: {
            readonly EVENTS: {
                readonly REPOSITORY: "softwareRepository";
                readonly DEVICE_TAB: "deviceSoftware";
            };
            readonly COMPONENTS: {
                readonly ADD_SOFTWARE_MODAL: "add-software-modal";
                readonly DEVICE_SOFTWARE_CHANGES: "device-software-changes";
                readonly DEVICE_SOFTWARE_LIST: "device-software-list";
            };
            readonly ACTIONS: {
                readonly APPLY_SOFTWARE_CHANGES: "applySoftwareChanges";
                readonly CLEAR_SOFTWARE_CHANGES: "clearSoftwareChanges";
                readonly OPEN_INSTALL_SOFTWARE: "openInstallSoftwareModal";
                readonly OPEN_UPDATE_SOFTWARE: "openUpdateSoftwareModal";
                readonly DELETE_SOFTWARE: "deleteSoftware";
            };
            readonly RESULTS: {
                readonly ADD_SOFTWARE: "addSoftware";
                readonly ADD_SOFTWARE_VERSION: "addSoftwareVersion";
                readonly EDIT_SOFTWARE: "editSoftware";
            };
        };
        readonly FIRMWARE: {
            readonly EVENTS: {
                readonly REPOSITORY: "firmwareRepository";
                readonly DEVICE_TAB: "deviceFirmware";
            };
            readonly COMPONENTS: {
                readonly ADD_FIRMWARE_MODAL: "add-firmware-modal";
                readonly ADD_FIRMWAR_PATCH_MODAL: "add-firmware-patch-modal";
                readonly FIRMWARE_DEVICE_TAB: "firmware-device-tab";
                readonly DEVICE_FIRMWARE_LIST: "device-firmware-list";
            };
            readonly ACTIONS: {
                readonly OPEN_INSTALL_FIRMWARE_DIALOG: "openInstallFirmwareDialog";
                readonly OPEN_REPLACE_FIRMWARE_DIALOG: "openReplaceFirmwareDialog";
                readonly OPEN_INSTALL_FIRMWARE_PATCH_DIALOG: "openInstallFirmwarePatchDialog";
            };
            readonly RESULTS: {
                readonly ADD_FIRMWARE: "addFirmware";
                readonly ADD_FIRMWARE_VERSION: "addFirmwareVersion";
                readonly ADD_FIRMWARE_PATCH: "addFirmwarePatch";
                readonly EDIT_FIRMWARE: "editFirmware";
                readonly CREATE_FIRMWARE_UPDATE_OPERATION: "createFirmwareUpdateOperation";
            };
        };
        readonly SHARED: {
            readonly COMPONENTS: {
                readonly REPOSITORY_SELECT_MODAL: "repository-select-modal";
                readonly SELECT_CONFIGURATION_MODAL: "select-configuration-modal";
            };
        };
    };
    form: NgForm;
    saved: EventEmitter<RepositoryCategory>;
    onInput: BehaviorSubject<string>;
    model: ModalModel;
    firmwaresResult: any;
    saving: boolean;
    firmwarePreselected: boolean;
    textForFirmwareUrlPopover: string;
    ValidationPattern: typeof ValidationPattern;
    private inputSubscription$;
    constructor(modal: BsModalRef, repositoryService: RepositoryService, alert: AlertService);
    ngOnInit(): void;
    setInitialState(): void;
    loadFirmwares(): void;
    getFirmwareResult(searchStr: string): rxjs.Observable<_c8y_client.IResultList<IManagedObject>>;
    save(): Promise<void>;
    successMsg(): void;
    cancel(): void;
    ngOnDestroy(): void;
    onFile(dropped: PickedFiles): void;
    onFirmwareSelect(firmware: IManagedObject): void;
    static ɵfac: i0.ɵɵFactoryDeclaration<AddFirmwareModalComponent, never>;
    static ɵcmp: i0.ɵɵComponentDeclaration<AddFirmwareModalComponent, "c8y-add-firmware-software-modal", never, {}, { "saved": "saved"; }, never, never, true, never>;
}

declare class FirmwareDetailsComponent implements OnInit, OnDestroy {
    private activatedRoute;
    private inventoryService;
    private repositoryService;
    private alertService;
    private translateService;
    private modalService;
    private bsModalService;
    private gainsightService;
    private router;
    reload$: Subject<void>;
    reloading$: BehaviorSubject<boolean>;
    firmware: IManagedObject;
    updateFirmware$: Subject<Partial<IManagedObject>>;
    firmwareUpdated$: Subject<IManagedObject>;
    baseVersionsUpdated$: Subject<void>;
    patchVersionsUpdated$: Subject<void>;
    firmware$: Observable<IManagedObject>;
    baseVersions$: Observable<IResultList<IManagedObject>>;
    isLegacy$: Observable<boolean>;
    canAddPatchVersions$: Observable<boolean>;
    expanded: {
        [id: string]: boolean;
    };
    destroy$: Subject<boolean>;
    constructor(activatedRoute: ActivatedRoute, inventoryService: InventoryService, repositoryService: RepositoryService, alertService: AlertService, translateService: TranslateService, modalService: ModalService, bsModalService: BsModalService, gainsightService: GainsightService, router: Router);
    ngOnInit(): void;
    getPatchVersionsCount$(baseVersion: FirmwareBinary): Observable<number>;
    getBinaryName$(binaryUrl: any): Observable<string>;
    getPatchVersions$(baseVersion: any): Observable<IResultList<IManagedObject>>;
    addBaseVersion(): void;
    addPatchVersion(): void;
    deleteBaseVersion(baseVersion: IManagedObject): Promise<void>;
    deletePatchVersion(patchVersion: IManagedObject): Promise<void>;
    ngOnDestroy(): void;
    static ɵfac: i0.ɵɵFactoryDeclaration<FirmwareDetailsComponent, never>;
    static ɵcmp: i0.ɵɵComponentDeclaration<FirmwareDetailsComponent, "c8y-firmware-details", never, {}, {}, never, never, true, never>;
}

declare class FirmwareListComponent {
    private repositoryService;
    private gridService;
    private modalService;
    private bsModalService;
    private translateService;
    private alertService;
    private router;
    private activatedRoute;
    sizeRequest: Promise<number>;
    sizeRequestDone: boolean;
    refresh$: EventEmitter<void>;
    isDataPresent$: Observable<boolean>;
    columns: Column[];
    actionControls: ActionControl[];
    serverSideDataCallback: ServerSideDataCallback;
    pagination: {
        pageSize: number;
        currentPage: number;
    };
    noResultsMessage: "No results to display.";
    noDataMessage: "No firmware to display.";
    noResultsSubtitle: "Refine your search terms or check your spelling.";
    noDataSubtitle: "Add a new firmware by clicking below.";
    constructor(repositoryService: RepositoryService, gridService: DataGridService, modalService: ModalService, bsModalService: BsModalService, translateService: TranslateService, alertService: AlertService, router: Router, activatedRoute: ActivatedRoute);
    ngOnInit(): void;
    addFirmware(): void;
    addFirmwarePatch(): void;
    editFirmware(firmware: Partial<IManagedObject>): void;
    deleteFirmware(firmware: IManagedObject): Promise<void>;
    onDataSourceModifier(dataSourceModifier: DataSourceModifier): Promise<ServerSideDataResult>;
    trackByName(_index: any, column: Column): string;
    static ɵfac: i0.ɵɵFactoryDeclaration<FirmwareListComponent, never>;
    static ɵcmp: i0.ɵɵComponentDeclaration<FirmwareListComponent, "c8y-firmware-list", never, {}, {}, never, never, true, never>;
}

declare class FirmwareRepositoryListModule {
    static forRoot(): ModuleWithProviders<FirmwareRepositoryListModule>;
    static ɵfac: i0.ɵɵFactoryDeclaration<FirmwareRepositoryListModule, never>;
    static ɵmod: i0.ɵɵNgModuleDeclaration<FirmwareRepositoryListModule, never, [typeof i1.SharedRepositoryModule, typeof FirmwareListComponent, typeof FirmwareDetailsComponent, typeof AddFirmwareModalComponent, typeof AddFirmwarePatchModalComponent], never>;
    static ɵinj: i0.ɵɵInjectorDeclaration<FirmwareRepositoryListModule>;
}

declare class FirmwareRepositoryModule {
    static ɵfac: i0.ɵɵFactoryDeclaration<FirmwareRepositoryModule, never>;
    static ɵmod: i0.ɵɵNgModuleDeclaration<FirmwareRepositoryModule, never, [typeof FirmwareRepositoryListModule, typeof FirmwareRepositoryDeviceTabModule], never>;
    static ɵinj: i0.ɵɵInjectorDeclaration<FirmwareRepositoryModule>;
}

export { AddFirmwareModalComponent, AddFirmwarePatchModalComponent, FirmwareDetailsComponent, FirmwareDeviceTabComponent, FirmwareDeviceTabGuard, FirmwareListComponent, FirmwareRepositoryDeviceTabModule, FirmwareRepositoryListModule, FirmwareRepositoryModule };
//# sourceMappingURL=index.d.ts.map
