convent method
Implementation
FirmwareUpgradeMode convent() {
switch (this) {
case ProtoFirmwareUpgradeConfiguration_FirmwareUpgradeMode.CONFIRM_ONLY:
return FirmwareUpgradeMode.confirmOnly;
case ProtoFirmwareUpgradeConfiguration_FirmwareUpgradeMode.TEST_ONLY:
return FirmwareUpgradeMode.testOnly;
case ProtoFirmwareUpgradeConfiguration_FirmwareUpgradeMode
.TEST_AND_CONFIRM:
return FirmwareUpgradeMode.testAndConfirm;
case ProtoFirmwareUpgradeConfiguration_FirmwareUpgradeMode.UPLOAD_ONLY:
return FirmwareUpgradeMode.uploadOnly;
default:
throw 'Unsupported FirmwareUpgradeMode';
}
}