WHAT DOES SYSTEM.GC() AND RUNTIME.GC() METHODS DO ?

Kamlakar Singh

Total Post:80

Points:400
Posted by  Kamlakar Singh
Java 
 675  View(s)
Ratings:
Rate this:
  1. Kamlakar Singh

    Post:80

    Points:400
    What does System.gc() and Runtime.gc() methods do ?

    These methods can be used as a hint to the JVM, in order to start a garbage collection. However, this it is up to the Java Virtual Machine (JVM) to start the garbage collection immediately or later in time.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!