(cls, arg: _LvmConfigurationSerialization, disk_config: DiskLayoutConfiguration)
| 1310 | |
| 1311 | @classmethod |
| 1312 | def parse_arg(cls, arg: _LvmConfigurationSerialization, disk_config: DiskLayoutConfiguration) -> Self: |
| 1313 | lvm_pvs = [] |
| 1314 | for mod in disk_config.device_modifications: |
| 1315 | for part in mod.partitions: |
| 1316 | # FIXME: 'lvm_pvs' does not seem like it can ever exist in the 'arg' serialization |
| 1317 | if part.obj_id in arg.get('lvm_pvs', []): # type: ignore[operator] |
| 1318 | lvm_pvs.append(part) |
| 1319 | |
| 1320 | return cls( |
| 1321 | config_type=LvmLayoutType(arg['config_type']), |
| 1322 | vol_groups=[LvmVolumeGroup.parse_arg(vol_group, disk_config) for vol_group in arg['vol_groups']], |
| 1323 | ) |
| 1324 | |
| 1325 | def get_all_pvs(self) -> list[PartitionModification]: |
| 1326 | pvs = [] |
nothing calls this directly
no test coverage detected