Package com.oracle.coherence.common.base
Interface Pollable<E>
public interface Pollable<E>
The Pollable interface describes a component which supports element removal.
- Author:
- mf 2013.02.19
-
Method Summary
-
Method Details
-
poll
E poll()Removes and returns the next element, or returns null if none is present.- Returns:
- the next element or null
-
poll
Removes and returns the next element, or returns null upon timeout.- Parameters:
timeout
- how long to wait before giving up, in units of unitunit
- a TimeUnit determining how to interpret the timeout parameter- Returns:
- the next element or null
- Throws:
InterruptedException
- if interrupted while waiting
-