MCPcopy Create free account
hub / github.com/apache/commons-lang / compare

Method compare

src/main/java/org/apache/commons/lang3/Strings.java:501–501  ·  view source on GitHub ↗

Compare two Strings lexicographically, like String#compareTo(String). The return values are: int = 0, if str1 is equal to str2 (or both null) int < 0, if str1 is less than str2 int > 0, if {@c

(String str1, String str2)

Source from the content-addressed store, hash-verified

499 * @return &lt; 0, 0, &gt; 0, if {@code str1} is respectively less, equal or greater than {@code str2}
500 */
501 public abstract int compare(String str1, String str2);
502
503 /**
504 * Tests if CharSequence contains a search CharSequence, handling {@code null}. This method uses {@link String#indexOf(String)} if possible.

Callers 2

isSortedMethod · 0.45
ClassUtilsClass · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected