If a class contains a variable named "blah", then the standard getter/setter syntax is obviously getBlah() and setBlah(). But if I have a POJO class with a variable named isBlah, would I use:
public type getIsBlah() {
return isBlah;
}
public setIsBlah(type isBlah) {
this.isBlah = isBlah;
}
Or would it be this?
public type isBlah() {
return isBlah;
}
public setBlah(type blah) {
this.isBlah = blah;
}
The first seems to conform more strictly to the POJO conventions, but the second type is what IntelliJ generates if I ask it to make a class' getter/setters (and hey, IntelliJ has never let me down yet :] ). So which is the preferred syntax?