> Setting objects as null will make the object
> eligible for GC

That should read "may make".  If there are other
references to the object ( perhaps another reference
to the exists in a Hashmap or Hashtable somewhere ), 
it will only be eligible once all references to the
object have been cleared ( otherwise the object is
"retained" ).
-------------------------------------------
What do Bruce Eckel, Roedy Green and Professor Baldwin
have in common?
http://www.enterprisedeveloper.com/jcertify
Free Trial download

--- Narasimhan Sethuraman <[EMAIL PROTECTED]> wrote:

<HR>
<html><div style='background-color:'><DIV></DIV>
<DIV>
<DIV>
<P>You can't&nbsp; customize GC. It is JVM
dependant.&nbsp; Setting&nbsp; objects&nbsp; as&nbsp;
null will make the object eligible for GC</P></DIV>
<P>Narasimhan</P>
<P>H Shankaranarayanan wrote: </P>
<DIV></DIV>
<DIV></DIV>
<P>&gt;You can get the free memory available at that
instant and display </P>
<DIV></DIV>
<P>&gt;it. </P>
<DIV></DIV>
<P>&gt;The heap size is not accessible . </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt;see Runtime.freeMemory() and
Runtime.totalMemory() for this. </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt;Reg customization of a GC i have no idea. Cud
some one throw light </P>
<DIV></DIV>
<P>&gt;on </P>
<DIV></DIV>
<P>&gt;that one? </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>How does one customize the GC? Or do you mean just
allow the user to </P>
<DIV></DIV>
<P>make a selection and your code executes
System.GC()? If the latter, </P>
<DIV></DIV>
<P>there should be no side effects as the GC runs at
arbitrary times </P>
<DIV></DIV>
<P>anyway. Even calling System.GC() does nothing more
than *suggest* that </P>
<DIV></DIV>
<P>garbage collection may take place. The VM is still
free to schedule it </P>
<DIV></DIV>
<P>for whenever it chooses. </P>
<DIV></DIV>
<DIV></DIV>
<P>Tomm </P>
<DIV></DIV>
<DIV></DIV>
<P>&gt; From: SAMINATHAN [<A
href="mailto:[EMAIL PROTECTED]";>mailto:[EMAIL PROTECTED]</A>]
</P>
<DIV></DIV>
<P>&gt; Sent: Thursday, June 20, 2002 10:05 AM </P>
<DIV></DIV>
<P>&gt; To: JDJList </P>
<DIV></DIV>
<P>&gt; Subject: [jdjlist] Heap Size of the JVM </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; How do i find a heap size of my JVM.I need to
display that in </P>
<DIV></DIV>
<P>&gt;my </P>
<DIV></DIV>
<P>&gt; application. </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; And </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; If i allow user to use Customized garbage
collector , what side </P>
<DIV></DIV>
<P>&gt; effects it will make? </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; Thanks and Regards </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt; Saminathan. </P>
<P>To change your membership options, refer to: </P>
<DIV></DIV>
<P>&gt; http://www.sys-con.com/java/list.cfm </P>
<DIV></DIV>
<P>&gt; </P>
<DIV></DIV>
<P>&gt;To change your membership options, refer to:
</P>
<DIV></DIV>
<P>&gt;http://www.sys-con.com/java/list.cfm </P>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<DIV></DIV>
<P>To change your membership options, refer to: </P>
<DIV></DIV>
<P>http://www.sys-con.com/java/list.cfm </P>
<DIV></DIV>
<P><BR clear=all>&nbsp;</P></DIV></div><br
clear=all><hr>Send and receive Hotmail on your mobile
device: <a href='http://g.msn.com/1HM503401/38'>Click
Here</a><br>
To change your membership options, refer to:
<BR>
http://www.sys-con.com/java/list.cfm
</html>



__________________________________________________
Do You Yahoo!?
Yahoo! - Official partner of 2002 FIFA World Cup
http://fifaworldcup.yahoo.com

To change your membership options, refer to:
http://www.sys-con.com/java/list.cfm

Reply via email to