MCPcopy Create free account
hub / github.com/codenameone/CodenameOne / hashCode

Method hashCode

Ports/CLDC11/src/java/util/Arrays.java:1218–1228  ·  view source on GitHub ↗
(boolean[] array)

Source from the content-addressed store, hash-verified

1216 ///
1217 /// the hash code for `array`.
1218 public static int hashCode(boolean[] array) {
1219 if (array == null) {
1220 return 0;
1221 }
1222 int hashCode = 1;
1223 for (boolean element : array) {
1224 // 1231, 1237 are hash code values for boolean value
1225 hashCode = 31 * hashCode + (element ? 1231 : 1237);
1226 }
1227 return hashCode;
1228 }
1229
1230 /// Returns a hash code based on the contents of the given array. For any two
1231 /// not-null `int` arrays `a` and `b`, if

Callers 2

hashMethod · 0.95
hashCodeMethod · 0.95

Calls 3

floatToIntBitsMethod · 0.95
doubleToLongBitsMethod · 0.95
hashCodeMethod · 0.65

Tested by

no test coverage detected