T
- the type of the reference object
Reference queues, to which registered reference objects are appended by the garbage collector after the appropriate reachability changes are detected.
Constructors
Constructs a new reference-object queue.
Polls this queue to see if a reference object is available.
Removes the next reference object in this queue, blocking until one becomes available.
Removes the next reference object in this queue, blocking until either one becomes available or the given timeout period expires.
Methods declared in class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public ReferenceQueue()
Constructs a new reference-object queue.
Polls this queue to see if a reference object is available. If one is available without further delay then it is removed from the queue and returned. Otherwise this method immediately returns null
.
null
This method does not offer real-time guarantees: It schedules the timeout as if by invoking the Object.wait(long)
method.
timeout
- If positive, block for up to timeout
milliseconds while waiting for a reference to be added to this queue. If zero, block indefinitely.
null
IllegalArgumentException
- If the value of the timeout argument is negative
InterruptedException
- If the timeout wait is interrupted
Removes the next reference object in this queue, blocking until one becomes available.
InterruptedException
- If the wait is interrupted
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4