<p>This method calls the equals or compareTo methods on a String variable passing in a String literal.
A NullPointerException may occur if the string variable is null. If instead the method was called on
the string literal, and the variable was passed as an argument, this exception could never happen.</p>