is origination an lifeless twine consistent value it?
i have co-worker swears by
//in essay "constants" class
public stationary final twine empty_string = "";
in constants category accessible via project. way, something like
if (constants.empty_string.equals(otherstring)) {
...
}
instead
if ("".equals(otherstring)) {
...
}
i contend it's
- not value it--it doesn't save any space heap/stack/string pool,
- ugly
- abuse constants class.
who crazy here?
Comments
Post a Comment