The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
April 2001

Advertisement

Advertisement

This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.

Message:

Sir, they are same...

Posted by KIshori Sharan on June 29, 2001 at 10:14 AM

Bo calls the same native method. In fact, System.gc() calls the gc() method of Runtime. Following is the code for gc() method in System class. Therefore, when you call System.gc() internally it calls Runtime.getRuntime().gc().

// gc() method in System class
public static void gc() {
Runtime.getRuntime().gc();
}






Replies:

Sponsored Links



Google
  Web Artima.com   
Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us