Example usage for java.lang Double hashCode

List of usage examples for java.lang Double hashCode

Introduction

In this page you can find the example usage for java.lang Double hashCode.

Prototype

public static int hashCode(double value) 

Source Link

Document

Returns a hash code for a double value; compatible with Double.hashCode() .

Usage

From source file:com.cloudera.oryx.common.math.DoubleWeightedMean.java

@Override
public int hashCode() {
    return Long.hashCode(count) ^ Double.hashCode(totalWeight) ^ Double.hashCode(mean);
}

From source file:net.mintern.primitive.pair.DoublePair.java

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code//from   ww w.j a  va  2s  .  c  o  m
 * @see Double#hashCode(double)
 */
@Override
public int hashCode() {
    return Double.hashCode(getLeft()) ^ Double.hashCode(getRight());
}

From source file:net.mintern.primitive.pair.DoubleBytePair.java

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code//from   ww w.ja  va 2 s .c om
 * @see Double#hashCode(double)
 * @see Byte#hashCode(byte)
 */
@Override
public int hashCode() {
    return Double.hashCode(getLeft()) ^ Byte.hashCode(getRight());
}

From source file:net.mintern.primitive.pair.DoubleIntPair.java

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code//from  w w  w  .j  ava 2  s.c  o m
 * @see Double#hashCode(double)
 * @see Integer#hashCode(int)
 */
@Override
public int hashCode() {
    return Double.hashCode(getLeft()) ^ Integer.hashCode(getRight());
}

From source file:net.mintern.primitive.pair.DoubleLongPair.java

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code//from   w  w w.ja  v  a 2s  .com
 * @see Double#hashCode(double)
 * @see Long#hashCode(long)
 */
@Override
public int hashCode() {
    return Double.hashCode(getLeft()) ^ Long.hashCode(getRight());
}

From source file:net.mintern.primitive.pair.DoubleFloatPair.java

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code//ww  w.  j a va2s  .  c  o m
 * @see Double#hashCode(double)
 * @see Float#hashCode(float)
 */
@Override
public int hashCode() {
    return Double.hashCode(getLeft()) ^ Float.hashCode(getRight());
}

From source file:net.mintern.primitive.pair.DoubleCharPair.java

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code/*from w  ww.j  a va  2s.c  o m*/
 * @see Double#hashCode(double)
 * @see Character#hashCode(char)
 */
@Override
public int hashCode() {
    return Double.hashCode(getLeft()) ^ Character.hashCode(getRight());
}

From source file:net.mintern.primitive.pair.DoubleBooleanPair.java

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code//from  www.j  a v a 2  s .  c o  m
 * @see Double#hashCode(double)
 * @see Boolean#hashCode(boolean)
 */
@Override
public int hashCode() {
    return Double.hashCode(getLeft()) ^ Boolean.hashCode(getRight());
}

From source file:net.mintern.primitive.pair.ObjDoublePair.java

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code/*from w w  w . j  ava2  s.  c o m*/
 * @see Objects#hashCode(Object)
 * @see Double#hashCode(double)
 */
@Override
public int hashCode() {
    return Objects.hashCode(getLeft()) ^ Double.hashCode(getRight());
}