aboutsummaryrefslogtreecommitdiff
path: root/libjava/doc/java-lang-ref.texi
blob: 4b9d78795385c98a50427924406693cb4e7f7212 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
@deftypemethod PhantomReference {public Object} get () 
Returns the object, this reference refers to.
@end deftypemethod
@deftypemethod Reference {public Object} get () 
Returns the object, this reference refers to.
@end deftypemethod
@deftypemethod Reference {public void} clear () 
Clears the reference, so that it doesn't refer to its object
 anymore.  For soft and weak references this is called by the
 garbage collection.  For phantom references you should call 
 this when enqueuing the reference.
@end deftypemethod
@deftypemethod Reference {public boolean} isEnqueued () 
Tells if the object is enqueued on a reference queue.
@end deftypemethod
@deftypemethod Reference {public boolean} enqueue () 
Enqueue an object on a reference queue.  This is normally executed
 by the garbage collection.
@end deftypemethod
@deftypemethod ReferenceQueue {public synchronized Reference} poll () 
Checks if there is a reference on the queue, returning it
 immediately.  The reference will be dequeued.
@end deftypemethod
@deftypemethod ReferenceQueue {public synchronized Reference} remove (long@w{ }@var{timeout}) @*throws InterruptedException
Removes a reference from the queue, blocking for @code{timeout}
 until a reference is enqueued.
@end deftypemethod
@deftypemethod ReferenceQueue {public Reference} remove () @*throws InterruptedException
Removes a reference from the queue, blocking until a reference is
 enqueued.
@end deftypemethod
@deftypemethod SoftReference {public Object} get () 
Returns the object, this reference refers to.
@end deftypemethod