Allon Mureinik has posted comments on this change.
Change subject: core: Changes type of VmDevice from String to enum
......................................................................
Patch Set 1: (1 inline comment)
A stupid question:
Why do we need VmDevice.type AND VmDevice.device?
what's the difference?
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/utils/VmDeviceUtils.java
Line 185: updateUSBSlots(null, vmBase);
Line 186: // add mem balloon if defined
Line 187: updateMemoryBalloon(null, vmBase,
vm.isBalloonEnabled());
Line 188: }
Line 189: if (VmDeviceGeneralType.DISK == device.getType()
Now that you're depending on the enum value and not a string, perhaps it would
be a good idea to convert the if-else to a switch-case?
Line 190: &&
VmDeviceType.DISK.getName().equals(device.getDevice())) {
Line 191: if (diskCount < disks.size()) {
Line 192: id = (disks.get(diskCount++)).getId();
Line 193: }
--
To view, visit http://gerrit.ovirt.org/14812
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Icada39e3918fb053cb0ad0388178ccf5c6338ca2
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Martin Peřina <[email protected]>
Gerrit-Reviewer: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Alona Kaplan <[email protected]>
Gerrit-Reviewer: Arik Hadas <[email protected]>
Gerrit-Reviewer: Michal Skrivanek <[email protected]>
Gerrit-Reviewer: Moti Asayag <[email protected]>
Gerrit-Reviewer: Omer Frenkel <[email protected]>
Gerrit-Reviewer: Roy Golan <[email protected]>
Gerrit-Reviewer: Yair Zaslavsky <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches