CLOUDSTACK-10362: Change the "getXXX" method names to "isXXX".#2600
CLOUDSTACK-10362: Change the "getXXX" method names to "isXXX".#2600yadvr merged 1 commit intoapache:masterapache/cloudstack:masterfrom Kui-Liu:BooleansCopy head branch name to clipboard
Conversation
These Boolean-return methods are named "getXXX", but other Boolean-return methods are named "isXXX", such as the following two methods. They will return boolean values, rename them as "isXXX" should be more clear than "getXXX".
DaanHoogland
left a comment
There was a problem hiding this comment.
I am fine wit most of the changes from a coding perspective, though I don't agree with all the choices made but my biggest concern is that some paring ort code generation relying on nameconventions will break with this. So I think intensive testing is required.
| } | ||
|
|
||
| public Boolean getDisplayVm() { | ||
| public Boolean isDisplayVm() { |
There was a problem hiding this comment.
this one is strange. it means to say shouldDisplayVm() but is can live with it
| } | ||
|
|
||
| public Boolean getDisplayVpc() { | ||
| public Boolean isDisplayVpc() { |
There was a problem hiding this comment.
same here; shouldDisplayVpc()??
| } | ||
|
|
||
| public Boolean getHasEnoughCapacity() { | ||
| public Boolean hasEnoughCapacity() { |
| } | ||
|
|
||
| public Boolean getDefaultUse() { | ||
| public Boolean isDefaultUse() { |
There was a problem hiding this comment.
isForDefaultUse() ??!?
| } | ||
|
|
||
| public Boolean getListAll() { | ||
| public Boolean isListAll() { |
|
@blueorangutan package |
|
@DaanHoogland a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress. |
|
Packaging result: ✔centos6 ✔centos7 ✔debian. JID-1989 |
|
@blueorangutan test |
|
@DaanHoogland a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests |
|
Trillian test result (tid-2589)
|
|
these test resulta are dissappointing so i did a recursive case insensitive search of the changed method names: no results are good results. I think we can go agead with this @rhtyd @rafaelweingartner ? |
|
@DaanHoogland so you checked it, and it seems that everything is ok? Is that it? |
…uds' Correção na migração de VMs com ISO anexada Closes apache#2600 See merge request scclouds/scclouds!1188
These Boolean-return methods are named "getXXX",
but other Boolean-return methods are named "isXXX", such as the following two methods.
They will return boolean values, rename them as "isXXX" should be more clear than "getXXX".
api/src/main/java/org/apache/cloudstack/api/command/admin/vlan/ListVlanIpRangesCmd.java
api/src/main/java/org/apache/cloudstack/api/command/user/address/ListPublicIpAddressesCmd.java