hi Friends,
i want information about garbage collector purpose in .net
can anyone explain through the small example ...please...........thanks in advance...............
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question.
Jignesh TrivediPosted Apr 18, 2012, 11:52 PM
please refer
http://msdn.microsoft.com/en-us/magazine/bb985010.aspx
http://msdn.microsoft.com/en-us/library/ms973837.aspx
good article on GC.
hope this help.
SenthilkumarPosted Apr 18, 2012, 1:48 PM
The garbage collection (GC) is new feature in Microsoft .net framework. When we have a class that represents an object in the runtime that allocates a memory space in the heap memory. All the behavior of that objects can be done in the allotted memory in the heap. Once the activities related to that object is get finished then it will be there as unused space in the memory.
The earlier releases of Microsoft products have used a method like once the process of that object get finished then it will be cleared from the memory. For instance Visual Basic, An object get finishes that work then there we have to define a "nothing" to that object. So, it clears the memory space to the processors.
Microsoft was planning to introduce a method that should automate the cleaning of unused memory space in the heap after the life time of that object. Eventually they have introduced a new technique "Garbage collection". It is very important part in the .Net framework. Now it handles this object clear in the memory implicitly. It overcomes the existing explicit unused memory space clearance.
for more info:
http://www.c-sharpcorner.com/uploadfile/skumaar_mca/garbage-collection-in-net-framework/
VulpesPosted Apr 18, 2012, 10:09 AM
http://www.c-sharpcorner.com/uploadfile/riteshratna/garbage-collection-memory-management-in-net/