|
||||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
java.lang.Objectorg.eclipse.jdt.internal.compiler.codegen.IntegerCache
public class IntegerCache
| 字段摘要 | |
|---|---|
int[] |
keyTable
|
int[] |
valueTable
|
| 构造方法摘要 | |
|---|---|
IntegerCache()
Constructs a new, empty hashtable. |
|
IntegerCache(int initialCapacity)
Constructs a new, empty hashtable with the specified initial capacity. |
|
| 方法摘要 | |
|---|---|
void |
clear()
Clears the hash table so that it has no more elements in it. |
boolean |
containsKey(int key)
Returns true if the collection contains an element for the key. |
int |
hash(int key)
Return a hashcode for the value of the key parameter. |
int |
put(int key,
int value)
Puts the specified element into the hashtable, using the specified key. |
int |
putIfAbsent(int key,
int value)
Puts the specified element into the hashtable if absent, using the specified key. |
int |
size()
Returns the number of elements contained in the hashtable. |
String |
toString()
Converts to a rather lengthy String. |
| 从类 java.lang.Object 继承的方法 |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| 字段详细信息 |
|---|
public int[] keyTable
public int[] valueTable
| 构造方法详细信息 |
|---|
public IntegerCache()
public IntegerCache(int initialCapacity)
initialCapacity - int
the initial number of buckets| 方法详细信息 |
|---|
public void clear()
public boolean containsKey(int key)
key - double the key that we are looking for
public int hash(int key)
key - int
public int put(int key,
int value)
key - int the specified key in the hashtablevalue - int the specified element
public int putIfAbsent(int key,
int value)
key - int the specified key in the hashtablevalue - int the specified element
public int size()
int The size of the tablepublic String toString()
Object 中的 toString
|
||||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||