|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.AbstractMap<K,V>
java.util.HashMap
org.walluck.oscar.SNACHashMap
public class SNACHashMap
A hash table for storing sent SNAC's.
Constructor Summary | |
---|---|
SNACHashMap(AIMSession sess,
AIMConnection conn)
Creates a new SNAC hash table with the default size. |
|
SNACHashMap(AIMSession sess,
AIMConnection conn,
int size)
Creates a new SNAC hash table with the given size. |
Method Summary | |
---|---|
int |
clean(int maxAge)
Clean out SNAC's over a certain number of seconds old. |
SNAC |
peek(int snacId)
Peek at a SNAC in the hash table. |
SNAC |
put(SNAC snac)
Put a SNAC into the hash table. |
SNAC |
remove(int snacId)
Remove a SNAC from the hash table. |
Methods inherited from class java.util.HashMap |
---|
clear, clone, containsKey, containsValue, entrySet, get, isEmpty, keySet, put, putAll, remove, size, values |
Methods inherited from class java.util.AbstractMap |
---|
equals, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.Map |
---|
equals, hashCode |
Constructor Detail |
---|
public SNACHashMap(AIMSession sess, AIMConnection conn)
sess
- the oscar sessionconn
- the connectionpublic SNACHashMap(AIMSession sess, AIMConnection conn, int size)
sess
- the oscar sessionconn
- the connectionsize
- the size of this hash tableMethod Detail |
---|
public SNAC put(SNAC snac)
snac
- the SNAC to put in the hash table
public SNAC peek(int snacId)
snacId
- the ID of the SNAC to look for
public SNAC remove(int snacId)
snacId
- the ID of the SNAC to remove
public int clean(int maxAge)
maxAge
- the maximum age for the SNAC's, in seconds
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |