Lior Vernia has posted comments on this change.

Change subject: webadmin: Edit vNic Profile- disable pm if the profile is used 
by a vm
......................................................................


Patch Set 3: -Code-Review

(1 comment)

http://gerrit.ovirt.org/#/c/24896/3/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/profiles/EditVnicProfileModel.java
File 
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/profiles/EditVnicProfileModel.java:

Line 64:         asyncQuery.asyncCallback = new INewAsyncCallback() {
Line 65:             @Override
Line 66:             public void onSuccess(Object model, Object ReturnValue)
Line 67:             {
Line 68:                 List<VM> vms = (List<VM>) ((VdcQueryReturnValue) 
ReturnValue).getReturnValue();
I would change that to Collection<VM>. You're not using any specific List 
functionality here, and this would improve flexibility and prevent breakage in 
case someone decides that it's better that the query returns a Set, for example.
Line 69:                 if (vms != null && !vms.isEmpty()) {
Line 70:                     
getPortMirroring().setChangeProhibitionReason(ConstantsManager.getInstance()
Line 71:                             .getConstants()
Line 72:                             .portMirroringNotChangedIfUsedByVms());


-- 
To view, visit http://gerrit.ovirt.org/24896
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I06b851dcfbae9cd1ba48fda20aa0d0db6c3cb6cc
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Alona Kaplan <alkap...@redhat.com>
Gerrit-Reviewer: Lior Vernia <lver...@redhat.com>
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to