Example usage for java.lang Boolean hashCode

List of usage examples for java.lang Boolean hashCode

Introduction

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

Prototype

public static int hashCode(boolean value) 

Source Link

Document

Returns a hash code for a boolean value; compatible with Boolean.hashCode() .

Usage

From source file:net.mintern.primitive.pair.BooleanPair.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 2  s .c  om*/
 * @see Boolean#hashCode(boolean)
 */
@Override
public int hashCode() {
    return Boolean.hashCode(getLeft()) ^ Boolean.hashCode(getRight());
}

From source file:net.mintern.primitive.pair.BooleanLongPair.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  a  v  a  2s  .c  o  m*/
 * @see Boolean#hashCode(boolean)
 * @see Long#hashCode(long)
 */
@Override
public int hashCode() {
    return Boolean.hashCode(getLeft()) ^ Long.hashCode(getRight());
}

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

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code//w  w  w  . j  a va 2 s.c om
 * @see Boolean#hashCode(boolean)
 * @see Integer#hashCode(int)
 */
@Override
public int hashCode() {
    return Boolean.hashCode(getLeft()) ^ Integer.hashCode(getRight());
}

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

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

From source file:net.mintern.primitive.pair.LongBooleanPair.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 Long#hashCode(long)
 * @see Boolean#hashCode(boolean)
 */
@Override
public int hashCode() {
    return Long.hashCode(getLeft()) ^ Boolean.hashCode(getRight());
}

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

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code//w  w w.j  a va  2 s. c  om
 * @see Integer#hashCode(int)
 * @see Boolean#hashCode(boolean)
 */
@Override
public int hashCode() {
    return Integer.hashCode(getLeft()) ^ Boolean.hashCode(getRight());
}

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

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

From source file:net.mintern.primitive.pair.CharBooleanPair.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  a v a  2s  . com
 * @see Character#hashCode(char)
 * @see Boolean#hashCode(boolean)
 */
@Override
public int hashCode() {
    return Character.hashCode(getLeft()) ^ Boolean.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   ww w.  j  a v  a 2s.co  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.ObjBooleanPair.java

/**
 * Returns a hash code that follows the definition in {@link java.util.Map.Entry#hashCode()}.
 *
 * @return the hash code/*from  w  ww .j av  a 2s .c  om*/
 * @see Objects#hashCode(Object)
 * @see Boolean#hashCode(boolean)
 */
@Override
public int hashCode() {
    return Objects.hashCode(getLeft()) ^ Boolean.hashCode(getRight());
}