Martin Peřina has posted comments on this change. Change subject: core: Add Entities.vmDevicesByDevice helper ......................................................................
Patch Set 1: (1 comment) https://gerrit.ovirt.org/#/c/38479/1/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Entities.java File backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/Entities.java: Line 106: } Line 107: Line 108: public static <E extends VmDevice> Map<String, E> vmDevicesByDevice(Collection<E> deviceList) { Line 109: if (deviceList != null) { Line 110: Map<String, E> map = new HashMap<String, E>(); Isn't it possible to use empty diamond? Map<String, E> map = new HashMap<>(); Line 111: for (E device : deviceList) { Line 112: if (device.getDevice() != null) { Line 113: map.put(device.getDevice(), device); Line 114: } -- To view, visit https://gerrit.ovirt.org/38479 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Ifc23a6b74cdc25ece3b9c3703bb72b980463e5cf Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Martin Betak <[email protected]> Gerrit-Reviewer: Alona Kaplan <[email protected]> Gerrit-Reviewer: Arik Hadas <[email protected]> Gerrit-Reviewer: Martin Betak <[email protected]> Gerrit-Reviewer: Martin Peřina <[email protected]> Gerrit-Reviewer: Omer Frenkel <[email protected]> Gerrit-Reviewer: Shahar Havivi <[email protected]> Gerrit-Reviewer: [email protected] Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
