What is the relation between Garbage collector and finalize
and destructor?

Answers were Sorted based on User's Feedback



What is the relation between Garbage collector and finalize and destructor?..

Answer / kanak

GC checks for those resources which are no longer used by
the process. To release the memory from these resources and
in order to regain the memory heap GC initiates destructors
to destroy such instances of the program. Before the
destructor void an instance variable finalize routine gets
executed. This routine performs whatever is to be done
before the object return to void state or prior to release
of any unused resources.

Is This Answer Correct ?    6 Yes 2 No

What is the relation between Garbage collector and finalize and destructor?..

Answer / aparna

here the GC calls an object's FINALIZE metod immediately
befoer it collects an object that is no longer reffered by
the application
GC doesnt actually run finalize metod when the GC finds a
FINALIZE method it queues the obj up for the finalizer to
execute the objects metod

Is This Answer Correct ?    4 Yes 3 No

Post New Answer

More VB.NET Interview Questions

What is the difference between import system.data.sqlclient and system.data.oledb?

0 Answers  


Why do we use byref keyword in vb.net?

0 Answers  


when do we need a multiple document interface?

2 Answers  


What is the difference between custom control and user control?

0 Answers  


Can you please explain the difference between namespace and assembly?

0 Answers  






Explain the difference between dispose and finalize()?

0 Answers  


my project run very wel in my sytem yhen i am deploying my project on client machine ,after deployment i run my project then it show " can no find server name " what i do .

0 Answers  


Sir, what code to store data from vb net sql server 2008 to 2005 and at the same time in order to validate the data entered is not the same, but there have been contacts in the module. Examples such as the log table that I created, the user name as the primary key.

0 Answers   Infosys,


what are the advantage in vb.net and different between vb and vb.net

6 Answers   Data Entry Operator, Infosys, TCS, Zansa,


Why do we use ansi keyword?

0 Answers  


How to Insert a TextBox value in to Sql database using VB.Net coding?

5 Answers  


What do you understand by vb.net?

0 Answers  


Categories