java.lang.Object
java.util.Dictionary
java.util.Hashtable
Freenet.node.LimitedHashtable
- All Implemented Interfaces:
- java.lang.Cloneable, java.util.Map, java.io.Serializable
- class LimitedHashtable
- extends java.util.Hashtable
A variant on a Hashtable which only holds a limited number of
messages. When more messages than that are put in, old ones are
deleted, oldest first.
- Version:
- Rrevision$
| Nested classes inherited from class java.util.Hashtable |
|
| Nested classes inherited from class java.util.Map |
java.util.Map.Entry |
| Fields inherited from class java.util.Hashtable |
|
| Methods inherited from class java.util.Hashtable |
clear, clone, contains, containsKey, containsValue, elements, entrySet, equals, get, hashCode, isEmpty, keys, keySet, putAll, rehash, remove, size, values |
ar
java.lang.Object[] ar
ptr
int ptr
LimitedHashtable
public LimitedHashtable(int size)
limput
public java.lang.Object[] limput(java.lang.Object key,
java.lang.Object value)
put
public java.lang.Object put(java.lang.Object key,
java.lang.Object value)
- Description copied from class:
java.util.Hashtable
- Puts the supplied value into the Map, mapped by the supplied key.
Neither parameter may be null. The value may be retrieved by any
object which
equals() this key.
toString
public java.lang.String toString()
- Description copied from class:
java.util.Hashtable
- Converts this Hashtable to a String, surrounded by braces, and with
key/value pairs listed with an equals sign between, separated by a
comma and space. For example,
"{a=1, b=2}".
NOTE: if the toString() method of any key or value
throws an exception, this will fail for the same reason.