Word of the Day: Tech Definitions from WhatIs.com

Mar 7 2008   12:41PM GMT

Overheard: Garbage collection

Margaret Rouse Margaret Rouse Profile: Margaret Rouse

garbage_can.jpg Here’s a pretty easy way to automatically collect unused memory. Put a counter on each object, signifying how many outside references there are to this object. When it gets to zero, you know there are no references to it, so it can be deleted.

When another object starts referencing that object, it needs to increment the reference count by one. When it stops referencing it, the referrer needs to decrement the reference count.

Daniel Ehrenberg, A quick intro to garbage collection

 Comment on this Post

There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when other members comment.

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

Share this item with your network: