org.mmbase.util
Class LRUHashtable.LRUEntry

java.lang.Object
  extended by org.mmbase.util.LRUHashtable.LRUEntry
All Implemented Interfaces:
Map.Entry<K,V>, SizeMeasurable
Enclosing class:
LRUHashtable<K,V>

public class LRUHashtable.LRUEntry
extends Object
implements Map.Entry<K,V>, SizeMeasurable

Element used to store information from the LRUHashtable.


Field Summary
protected  K key
          The element key
protected  LRUHashtable.LRUEntry next
          The next, newer, element
protected  LRUHashtable.LRUEntry prev
          The previous, older, element
protected  int requestCount
          the number of times this entry has been requested
protected  V value
          The element value
 
Constructor Summary
LRUHashtable.LRUEntry()
           
LRUHashtable.LRUEntry(K key, V val)
           
LRUHashtable.LRUEntry(K key, V value, LRUHashtable.LRUEntry prev, LRUHashtable.LRUEntry next)
           
 
Method Summary
 int getByteSize()
          Determines the byte-size of this object
 int getByteSize(SizeOf sizeof)
          Determines the byte-size of this object using the given SizeOf instance.
 K getKey()
           
 V getValue()
           
 V setValue(V o)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Map.Entry
equals, hashCode
 

Field Detail

value

protected V value
The element value


next

protected LRUHashtable.LRUEntry next
The next, newer, element


prev

protected LRUHashtable.LRUEntry prev
The previous, older, element


key

protected K key
The element key


requestCount

protected int requestCount
the number of times this entry has been requested

Constructor Detail

LRUHashtable.LRUEntry

LRUHashtable.LRUEntry()

LRUHashtable.LRUEntry

LRUHashtable.LRUEntry(K key,
                      V val)

LRUHashtable.LRUEntry

LRUHashtable.LRUEntry(K key,
                      V value,
                      LRUHashtable.LRUEntry prev,
                      LRUHashtable.LRUEntry next)
Method Detail

getKey

public K getKey()
Specified by:
getKey in interface Map.Entry<K,V>

getValue

public V getValue()
Specified by:
getValue in interface Map.Entry<K,V>

setValue

public V setValue(V o)
Specified by:
setValue in interface Map.Entry<K,V>

getByteSize

public int getByteSize()
Description copied from interface: SizeMeasurable
Determines the byte-size of this object

Specified by:
getByteSize in interface SizeMeasurable

getByteSize

public int getByteSize(SizeOf sizeof)
Description copied from interface: SizeMeasurable
Determines the byte-size of this object using the given SizeOf instance. A SizeOf instance stores a Set already counted objects. So this method is typically called by SizeOf itself (recursion).

Specified by:
getByteSize in interface SizeMeasurable

toString

public String toString()
Overrides:
toString in class Object


MMBase 2.0-SNAPSHOT - null