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

Method hashCode

CodenameOne/src/com/codename1/ui/Transform.java:1050–1065  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1048 }
1049
1050 @Override
1051 public int hashCode() {
1052 if (type == TYPE_IDENTITY) {
1053 return 0;
1054 }
1055 int hash = 7;
1056 hash = 29 * hash + this.type;
1057 hash = 29 * hash + (this.nativeTransform != null ? this.nativeTransform.hashCode() : 0);
1058 hash = 29 * hash + Float.floatToIntBits(this.translateX);
1059 hash = 29 * hash + Float.floatToIntBits(this.translateY);
1060 hash = 29 * hash + Float.floatToIntBits(this.translateZ);
1061 hash = 29 * hash + Float.floatToIntBits(this.scaleX);
1062 hash = 29 * hash + Float.floatToIntBits(this.scaleY);
1063 hash = 29 * hash + Float.floatToIntBits(this.scaleZ);
1064 return hash;
1065 }
1066
1067 private static class IdentityHolder {
1068 private static final Transform IDENTITY = createIdentity();

Callers 1

testHashCodeMethod · 0.95

Calls 2

floatToIntBitsMethod · 0.95
hashCodeMethod · 0.65

Tested by 1

testHashCodeMethod · 0.76