Comment on Tutorial - Garbage collection and Finalize() method By aathishankaran



Comment Added by : Amit

Comment Added at : 2011-07-25 05:26:47

Comment on Tutorial : Garbage collection and Finalize() method By aathishankaran
Gan,

Above print is not working because your object has not been garbage collected.If you want to print it , make reference of this object null and then call System.gc() and System.runFinalization().

Garbage collection happens automatically and you may not be sure when your object will be destroyed .


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. Great article! Simple and precise. Thanks!
View Tutorial          By: dz at 2014-10-06 04:36:56

2. hou to cal activity of one project into another pr
View Tutorial          By: manjunath at 2012-01-02 15:45:32

3. why java from two to the power 7 bit was upgraded
View Tutorial          By: avinash at 2013-05-28 08:34:24

4. Hay can you send me complete code to make connecti
View Tutorial          By: 9COOL at 2010-02-22 08:10:47

5. it doesn't count for the values like 001 or 02 et
View Tutorial          By: angesh at 2012-02-10 16:15:02

6. very easy to understand ... a quite a good example
View Tutorial          By: Dinesh at 2012-09-22 18:19:45

7. i searched a lot of sites but found the answer her
View Tutorial          By: ALIEN ATTACK at 2012-01-09 09:39:36

8. The above code given for sending SMS through your
View Tutorial          By: ROHAN at 2008-10-17 00:55:46

9. Sometimes java do support operator overloading as
View Tutorial          By: Gunjan Srivastava at 2011-07-06 09:14:00

10. Hi Its very useful ad nice article Thanks
View Tutorial          By: Hanish at 2011-07-22 13:12:23