import * as vscode from "vscode" ; import { TelemetryContext } from "./telemetry" ; import { constructAndLoadIoTProject } from "./utils" ; export class DeviceOperator { async compile ( context , channel , telemetryContext ) { const iotProject = await constructAndLoadIoTProject ( context , channel , telemetryContext ) ; if ( ! iotProject ) { return ; } await iotProject . compile ( ) ; } async upload ( context , channel , telemetryContext ) { const iotProject = await constructAndLoadIoTProject ( context , channel , telemetryContext ) ; if ( ! iotProject ) { return ; } await iotProject . upload ( ) ; } async configDeviceSettings ( context , channel , telemetryContext ) { const iotProject = await constructAndLoadIoTProject ( context , channel , telemetryContext ) ; if ( ! iotProject ) { return ; } await iotProject . configDeviceSettings ( ) ; } }