public final class HashCodeUtil extends Object
public int hashCode(){ final int result = HashCodeUtil.SEED; //collect the contributions of various fields result = HashCodeUtil.hash(result, fPrimitive); result = HashCodeUtil.hash(result, fObject); result = HashCodeUtil.hash(result, fArray); return result; }
Modifier and Type | Field and Description |
---|---|
static int |
SEED
An initial value for a hashCode, to which is added contributions
from fields.
|
Constructor and Description |
---|
HashCodeUtil() |
Modifier and Type | Method and Description |
---|---|
static int |
hash(int aSeed,
boolean aBoolean)
booleans.
|
static int |
hash(int aSeed,
boolean[] aArray)
Arrays of booleans.
|
static int |
hash(int aSeed,
byte[] aArray)
Arrays of bytes.
|
static int |
hash(int aSeed,
char aChar)
chars.
|
static int |
hash(int aSeed,
char[] aArray)
Arrays of chars.
|
static int |
hash(int aSeed,
double aDouble)
doubles.
|
static int |
hash(int aSeed,
double[] aArray)
Arrays of doubles.
|
static int |
hash(int aSeed,
float aFloat)
floats.
|
static int |
hash(int aSeed,
float[] aArray)
Arrays of floats.
|
static int |
hash(int aSeed,
int aInt)
ints.
|
static int |
hash(int aSeed,
int[] aArray)
Arrays of integers.
|
static int |
hash(int aSeed,
long aLong)
longs.
|
static int |
hash(int aSeed,
long[] aArray)
Arrays of longs
|
static int |
hash(int aSeed,
Object aObject)
Possibly-null Object fields.
|
static int |
hash(int aSeed,
Object[] aArray)
Arrays of Objects.
|
static int |
hash(int aSeed,
short[] aArray)
Arrays of shorts.
|
public static final int SEED
public HashCodeUtil()
public static int hash(int aSeed, boolean aBoolean)
public static int hash(int aSeed, char aChar)
public static int hash(int aSeed, int aInt)
public static int hash(int aSeed, long aLong)
public static int hash(int aSeed, float aFloat)
public static int hash(int aSeed, double aDouble)
public static int hash(int aSeed, boolean[] aArray)
public static int hash(int aSeed, char[] aArray)
public static int hash(int aSeed, byte[] aArray)
public static int hash(int aSeed, short[] aArray)
public static int hash(int aSeed, int[] aArray)
public static int hash(int aSeed, long[] aArray)
public static int hash(int aSeed, float[] aArray)
public static int hash(int aSeed, double[] aArray)
Copyright Hirondelle Systems - License - Generated 2013Sep20.10.58