import { defineTapPropertyExtension } from '@iotize/tap';
import { TapNLinkUpdater } from '@iotize/tap/firmware-update';

var ɵ0 = function (context) { return new TapFirmwareUpdateExtension(context); };
var _TAP_EXTENSION_FIRMWARE_UPDATE_ = defineTapPropertyExtension('firmwareUpdater', ɵ0);
/**
 * @deprecated use _TAP_EXTENSION_FIRMWARE_UPDATE_ instead
 */
var __DEFINED_PROPERTY_GETTER_FIRMWARE_UPDATE_ = _TAP_EXTENSION_FIRMWARE_UPDATE_;
var TapFirmwareUpdateExtension = /** @class */ (function () {
    function TapFirmwareUpdateExtension(context) {
        this.context = context;
    }
    TapFirmwareUpdateExtension.prototype.createLoader = function (packet, options) {
        return TapNLinkUpdater.create(this.context.tap, packet, options);
    };
    TapFirmwareUpdateExtension.prototype.apply = function (packet, options) {
        return this.createLoader(packet, options).asObservable();
    };
    return TapFirmwareUpdateExtension;
}());
// export function firmwareUpdater(
//     this: Tap,
//     options?: TapNLinkUpdater.Options
// ): TapNLinkUpdater {
//     return new TapNLinkUpdater(this, options);
// }
// Tap.prototype.firmwareUpdater = firmwareUpdater;

/**
 * Generated bundle index. Do not edit.
 */

export { _TAP_EXTENSION_FIRMWARE_UPDATE_, __DEFINED_PROPERTY_GETTER_FIRMWARE_UPDATE_ };
//# sourceMappingURL=iotize-tap-ext-firmware-update.js.map
