Why do we have equals() and equalsIgnoreCase() as two different methods, when equals() could have been overloaded with a special
equals()
equalsIgnoreCase()
It's absolutely possible to do what you are suggesting but the language designers chose to go the other way and hence we have equalsIgnoreCase(otherString) instead of say equals(otherString, StringConstants.IGNORE_CASE) or equals(otherString, true).
equalsIgnoreCase(otherString)
equals(otherString, StringConstants.IGNORE_CASE)
equals(otherString, true)