Vered Volansky has posted comments on this change.
Change subject: webadmin: Add host SPM priority value in host general tab
......................................................................
Patch Set 1: (5 inline comments)
....................................................
File
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/hosts/HostGeneralModel.java
Line 256: }
Line 257:
Line 258: public void setSpmPriorityValue(final Integer value) {
Line 259: if (spmPriorityValue == null ||
!spmPriorityValue.equals(value)) {
Line 260: this.spmPriorityValue = value;
No need for "this"
Line 261:
Line 262: if (spmMaxPriorityValue == null ||
spmDefaultPriorityValue == null) {
Line 263: getMaxSpmPriority();
Line 264: }
Line 267: }
Line 268: }
Line 269: }
Line 270:
Line 271: private void getMaxSpmPriority() {
No return value - why get?
Line 272: AsyncDataProvider.GetMaxSpmPriority(new AsyncQuery(this, new
INewAsyncCallback() {
Line 273: @Override
Line 274: public void OnSuccess(Object target, Object returnValue) {
Line 275: spmMaxPriorityValue = (Integer) returnValue;
Line 277: }
Line 278: }));
Line 279: }
Line 280:
Line 281: private void getDefaultSpmPriority() {
The same as above, why get?
Line 282: AsyncDataProvider.GetDefaultSpmPriority(new AsyncQuery(this,
new INewAsyncCallback() {
Line 283: @Override
Line 284: public void OnSuccess(Object target, Object returnValue) {
Line 285: spmDefaultPriorityValue = (Integer) returnValue;
Line 298: if (spmPriorityValue == null) {
Line 299: setSpmPriority(null);
Line 300: }
Line 301: else if (spmPriorityValue == spmLowPriorityValue) {
Line 302:
setSpmPriority(ConstantsManager.getInstance().getConstants().lowTitle());
4 uses of ConstantsManager.getInstance().getConstants(), consider moving into a
local variable.
Line 303: }
Line 304: else if (spmPriorityValue.equals(spmDefaultPriorityValue)) {
Line 305:
setSpmPriority(ConstantsManager.getInstance().getConstants().mediumTitle());
Line 306: }
Line 322: }
Line 323:
Line 324: public void setSpmPriority(String value) {
Line 325: if (spmPriority == null || !spmPriority.equals(value)) {
Line 326: this.spmPriority = value;
No need for "this"
Line 327: OnPropertyChanged(new
PropertyChangedEventArgs("SpmPriority")); //$NON-NLS-1$
Line 328: }
Line 329: }
Line 330:
--
To view, visit http://gerrit.ovirt.org/11895
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I9dc7b21ccb893b6d27443482b650659165dd40b6
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Tal Nisan <[email protected]>
Gerrit-Reviewer: Daniel Erez <[email protected]>
Gerrit-Reviewer: Vered Volansky <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches