Hi All, I am new to Java and I am confused Garbage Collection. Please explain me this with some good example. I want to know when exactly GC will be occur? Also want to know more about finalize() method.
Thanks in advance, Mubeen Shaik.
Sun Certified Java Programmer
Dirk Schreckmann
Sheriff
Joined: Dec 10, 2001
Posts: 7023
posted
0
I want to know when exactly GC will be occur? You can't. You're not intended to be able to do so. Also want to know more about finalize() method. What do you want to know? Perhaps you want to read the explanation contained in the Object class documentation. You might also like a read of Section 12.6 Finalization of Class Instances of the Java Language Specification.