garbage collection



Share on Google+Share on Google+

garbage collection
1 Answer(s)      8 years ago
Posted in : Java Beginners
View Answers

August 25, 2008 at 11:27 AM

Hi friend,

An object in a program is not used for long time then it will be automatically deleted by the garbage collector.
It save the some amount of memory.It identifies the objects that are no longer used by a program.
A Java object is subject to garbage collection when it becomes unreachable to the program in which it is used.
System.gc() method may be used to call it explicitly It is controlled by the JVM ,
The JVM runs periodically by using "mark" and "sweep"algorithms.Instead of "destructor"
in c++ , java supports garbage collector.

For read more information :



Related Tutorials/Questions & Answers:
garbage collection
garbage collection  how to use garbage collection in program using core java
Garbage collection
Garbage collection  why garbage collection? How it works?   Garbage collection is one of the most important features of Java. The purpose of garbage collection is to identify and discard objects that are no longer
Java garbage collection
Java garbage collection  What is Garbage Collection and how to call it explicitly
garbage collection in java
.style1 { color: #FFFFFF; } Garbage Collection in Java In java... through garbage collection. In other words it deallocate memory automatically which have no longer use. This technique is known as Garbage Collection
c++ garbage collection implementation
c++ garbage collection implementation  How to implement the garbage collection program in C
garbage collection - Java Beginners
object is subject to garbage collection when it becomes unreachable to the program...garbage collection  wat is the use of garbage collection  ... then it will be automatically deleted by the garbage collector. It save the some amount
garbage collection implementation dependent java
garbage collection implementation dependent java  How a garbage collection works in Java
Java garbage collection
Java garbage collection  Can an object be garbage collected while it is still reachable
Java garbage collection
Java garbage collection  How many times may an object's finalize() method be invoked by the garbage collector
php garbage collection sessions - PHP
php garbage collection sessions  i wanted to know more about the php garbage collection sessions.. how can i create and hold
Java garbage collection
Java garbage collection  Can an unreachable object become reachable again
What is garbage collection? - Java Beginners
What is garbage collection?   Hi, Tell me about garbage collection. How garbage collection works in java? Thanks   Garbage... Collection. The Garbage collection process is automatic and programmer can?t free
Java Garbage Collection
Java Garbage Collection      ... on garbage collection. The name "garbage collection" implies... but never freed explicitly by the code. Garbage collection is the process
Garbage collection process in java - Java Beginners
Garbage collection process in java  Name the process used for Garbage collection in Java? Thanks   Garbage collection process In Java the Garbage collection process is known as Garbage Collector. The Garbage
What is the purpose of garbage collection in Java, and when is it used?
What is the purpose of garbage collection in Java, and when is it used?  Hi, What is the purpose of garbage collection in Java, and when is it used... of Garbage collection in Java. so Please visit the link and clear your doubts
Garbage Collection
Garbage Collection      ... explicit Garbage Collection. Garbage Collection took 984 ms Staring explicit Garbage Collection. Garbage Collection took 16 ms
Code for Garbage Collection
Code for Garbage Collection  ... collection. First of all we have created an object for the garbage collector... the garbage collection on that object. Then we have used the System.currentTimeMillis
Java garbage collector
Java garbage collector  How you can force the garbage collection
Java garbage collector
Java garbage collector  Does garbage collection guarantee that a program will not run out of memory?  Hi, The Java Garbage Collector does not guarantee of this. Thanks
Garbage Collector
Garbage Collector  Hi, Can any one please tell me what are the types of garbage collector ?? Regards: Akash
Collection  What is the exact difference between lagacy classes and collection classes? and Enumeration is possible on Collection classes
collection  As we know array holds the similar kind of elements, then in collection how toArray() method will convert the collection having different objects as elements to an array in java
, Hashtable and Collections and Collection?   Enumeration : It is series... : It is re-sizable array implementation. Belongs to 'List' group in collection... Map in collection. Collections : It implements Polymorphic algorithms which
Collection  actually why do we need collections? means we can also store group of objects in relational data base and dbms also provides all the operatoins insert,delete,update,sort,search etc. then why collection
GARBAGE COLLECTOR  What is garbage collector in java?   In order to achieve run-time polymorphism in java following supports needed. At first overrides the super-class one or more methods in subclass this is due
garbage collector
garbage collector  Hi what is the adventage using system.gc() method ? what is the adventage f annotation in java ? how can we loads the spring...;Advantage of system.gc(): System.gc() runs the Garbage Collector.The JVM
Java garbage collector
Java garbage collector  What is the priority of Garbage collector thread
garbage collector - Java Interview Questions
garbage collector  what is the use of garbage collector?  ...; for (int i = 0; i < size; i++) { } System.out.println("Garbage Collection started explicitly."); long time = System.currentTimeMillis
Access Modifiers and Garbage Collection
Access Modifiers and Garbage Collection       Previously it was a requirement to allocate... step further in version 2.0 garbage collector is implemented as a conservative
Java garbage collector
Java garbage collector  Which is garbage collected first: Normal variables or static variables
Java Garbage collector
Java Garbage collector  What kind of thread is the Garbage collector thread?  Hi Friend, It is a daemon thread. Thanks
Java Spring Hibernate Struts Training What type of programming language is Java? How do beginners learn about Java? ClassNotFoundException HttpRequestInterceptor java.lang.noclassdeffounderror: org/apache/http/httprequest noclassdeffounderror: org/apache/http/client/methods/httpurirequest java.lang.NoClassDefFoundError: org/apache/http/client/HttpClient How do I resolve this Java Class not found exception? httpclient java.lang.NoClassDefFoundError Apache Commons ioutils maven dependency Read/Convert an inputStream to a String What is the meaning of Java Platform? Why Java is a platform independent language? What is the benefits of learning Core Java? Which technology should I learn after Java? What is array in java with example? How to Convert ArrayList to Array? How to substring in Java? How to format number in Java? What is instance variable in Java? How to download MySQL JDBC driver? What is Calendar class in Java? Which is the best Java tutorials for beginners? How to rename a file in Java? How to delete file in Java code? How to get day from date in Java using Calendar? How to get day of week in Java? How to calculate Date Difference in Java? How to compare date in Java? How to declare array in Java? How to calculate average of array in Java? What is Array in Java? write a java program to find the summation of all the integers entered on command line Sum of two numbers using command line arguments in Java How to create and use Array in Java? How to pass command line arguments in Java? How to create Applet Hello World? Appending String efficiently in Java How to append String in Java? How to list even numbers between 1 and 100? How to add BigDecimal in Java? What is Abstraction In Java? Which is best Beginners Java Tutorial? What is java.util package? Create list from array in Java Filter collection in Java 8 What is the best way to filter a Java Collection? Easy way to transform Collection to Array? How to convert Collection to Array in Java? What are Basic Java Language Elements? Advanced Java Tutorials in 2017


Advertisement null