|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface IntToIntMap
Interface defining a map from integers to integers
| Method Summary | |
|---|---|
void |
clear()
Clear the map. |
boolean |
find(int key)
Finds a key in the map. |
int |
get(int key)
Gets the value for this key. |
int |
getDefaultValue()
Get the default value used to indicate an unused entry |
IntIterator |
keyIterator()
Get an iterator over the integer key values held in the hash map |
void |
put(int key,
int value)
Adds a key-value pair to the map. |
boolean |
remove(int key)
Removes a key from the map. |
void |
setDefaultValue(int defaultValue)
Set the value to be returned to indicate an unused entry |
int |
size()
Gets the size of the map. |
| Method Detail |
|---|
void setDefaultValue(int defaultValue)
defaultValue - the value to be returned by get(int) if no entry
exists for the supplied keyint getDefaultValue()
get(int) if no entry
exists for the supplied keyvoid clear()
boolean find(int key)
key - Key
int get(int key)
key - Key
int size()
boolean remove(int key)
key - Key to remove
void put(int key,
int value)
key - Keyvalue - ValueIntIterator keyIterator()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||