Class StackMap<V extends Identifiable>
- java.lang.Object
-
- java.util.AbstractCollection<E>
-
- java.util.AbstractQueue<E>
-
- java.util.concurrent.LinkedBlockingQueue<V>
-
- edu.uiuc.ncsa.security.storage.sql.StackMap<V>
-
- All Implemented Interfaces:
Serializable
,Iterable<V>
,Collection<V>
,BlockingQueue<V>
,Queue<V>
public class StackMap<V extends Identifiable> extends LinkedBlockingQueue<V>
This will block until the capacity drops below max.Created by Jeff Gaynor
on 5/11/21 at 8:49 AM- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
HashMap<Identifier,V>
getMap()
V
poll()
V
poll(long timeout, TimeUnit unit)
void
put(V v)
boolean
remove(Object o)
V
take()
-
Methods inherited from class java.util.concurrent.LinkedBlockingQueue
contains, drainTo, drainTo, forEach, iterator, offer, offer, peek, remainingCapacity, removeAll, removeIf, retainAll, size, spliterator, toArray, toArray, toString
-
Methods inherited from class java.util.AbstractQueue
add, addAll, element, remove
-
Methods inherited from class java.util.AbstractCollection
containsAll, isEmpty
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.concurrent.BlockingQueue
add
-
Methods inherited from interface java.util.Collection
addAll, containsAll, equals, hashCode, isEmpty, parallelStream, stream, toArray
-
-
-
-
Method Detail
-
getMap
public HashMap<Identifier,V> getMap()
-
remove
public boolean remove(Object o)
- Specified by:
remove
in interfaceBlockingQueue<V extends Identifiable>
- Specified by:
remove
in interfaceCollection<V extends Identifiable>
- Overrides:
remove
in classLinkedBlockingQueue<V extends Identifiable>
-
take
public V take() throws InterruptedException
- Specified by:
take
in interfaceBlockingQueue<V extends Identifiable>
- Overrides:
take
in classLinkedBlockingQueue<V extends Identifiable>
- Throws:
InterruptedException
-
poll
public V poll()
- Specified by:
poll
in interfaceQueue<V extends Identifiable>
- Overrides:
poll
in classLinkedBlockingQueue<V extends Identifiable>
-
poll
public V poll(long timeout, TimeUnit unit) throws InterruptedException
- Specified by:
poll
in interfaceBlockingQueue<V extends Identifiable>
- Overrides:
poll
in classLinkedBlockingQueue<V extends Identifiable>
- Throws:
InterruptedException
-
put
public void put(V v) throws InterruptedException
- Specified by:
put
in interfaceBlockingQueue<V extends Identifiable>
- Overrides:
put
in classLinkedBlockingQueue<V extends Identifiable>
- Throws:
InterruptedException
-
clear
public void clear()
- Specified by:
clear
in interfaceCollection<V extends Identifiable>
- Overrides:
clear
in classLinkedBlockingQueue<V extends Identifiable>
-
-