net.sf.webmancer.util
Class HashCodeUtil
java.lang.Object
net.sf.webmancer.util.HashCodeUtil
public class HashCodeUtil
- extends java.lang.Object
- Author:
- Michal Burda
Field Summary |
static int |
SEED
An initial value for a hashCode , to which is added contributions from fields. |
Method Summary |
static int |
hash(int seed,
boolean value)
|
static int |
hash(int seed,
double value)
|
static int |
hash(int seed,
float value)
|
static int |
hash(int seed,
char value)
|
static int |
hash(int seed,
int value)
|
static int |
hash(int seed,
long value)
|
static int |
hash(int seed,
java.lang.Object value)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SEED
public static final int SEED
- An initial value for a
hashCode
, to which is added contributions from fields. Using a non-zero
value decreases collisons of hashCode
values.
- See Also:
- Constant Field Values
hash
public static int hash(int seed,
boolean value)
- Parameters:
seed
- value
-
- Returns:
hash
public static int hash(int seed,
char value)
- Parameters:
seed
- value
-
- Returns:
hash
public static int hash(int seed,
int value)
- Parameters:
seed
- value
-
- Returns:
hash
public static int hash(int seed,
long value)
- Parameters:
seed
- value
-
- Returns:
hash
public static int hash(int seed,
float value)
- Parameters:
seed
- value
-
- Returns:
hash
public static int hash(int seed,
double value)
- Parameters:
seed
- value
-
- Returns:
hash
public static int hash(int seed,
java.lang.Object value)
- Parameters:
seed
- value
-
- Returns:
Copyright © 2006-2007. All Rights Reserved.