| 9 | |
| 10 | |
| 11 | class NicType(Enum): |
| 12 | ISO = 'iso' |
| 13 | NM = 'nm' |
| 14 | NM_IWD = 'nm_iwd' |
| 15 | IWD = 'iwd' |
| 16 | MANUAL = 'manual' |
| 17 | |
| 18 | def display_msg(self) -> str: |
| 19 | match self: |
| 20 | case NicType.ISO: |
| 21 | return tr('Copy ISO network configuration to installation') |
| 22 | case NicType.NM: |
| 23 | return tr('Use Network Manager (default backend)') |
| 24 | case NicType.NM_IWD: |
| 25 | return tr('Use Network Manager (iwd backend)') |
| 26 | case NicType.IWD: |
| 27 | return tr('Use standalone iwd') |
| 28 | case NicType.MANUAL: |
| 29 | return tr('Manual configuration') |
| 30 | |
| 31 | |
| 32 | class _NicSerialization(TypedDict): |