

Hi,
Here is the answer.
Finalization is a facility provided by Java for classes who use native resources to clean up before the objects are garbage collected.
Java provides a method called finalize( ) that you can define for your class. Here s how it s supposed to work. When the garbage collector is ready to release the storage used for your object it will first call finalize( ) and only on the next garbage-collection pass will it reclaim the object s memory. So if you choose to use finalize( ) it gives you the ability to perform some important cleanup at the time of garbage collection.
Thanks.
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.