Geeks Talk

Prepare for your Next Interview




dispose,finalize

This is a discussion on dispose,finalize within the VB.NET forums, part of the Software Development category; Hi friends, I am little bit confused about dispose,finalize concepts...can anybody clarify these two concepts.......


Go Back   Geeks Talk > Software Development > VB.NET

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 02-12-2008
Junior Member
 
Join Date: Feb 2008
Location: bangalore
Posts: 18
Thanks: 0
Thanked 2 Times in 1 Post
venkat.rbs is on a distinguished road
dispose,finalize

Hi friends,
I am little bit confused about dispose,finalize concepts...can anybody clarify these two concepts....
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 02-13-2008
Moderator
 
Join Date: Jun 2007
Location: Bangalore,India
Posts: 1,432
Thanks: 8
Thanked 125 Times in 112 Posts
debasisdas will become famous soon enoughdebasisdas will become famous soon enough
Re: dispose,finalize

Quote:
Originally Posted by vikasvaidya View Post
Few quick points on Finalize() and Dispose() in C#:

1. Finalize() is the C# equivalent of destructor ~Object() syntax in C#. In VB.Net you implement the Finalize() by overriding it. But, in C# the compiler translates the destructor to a Finalize() method.

2. Finalize() can NOT be overridden or called in C#.

3. Since, Finalize() is called by the Garbage Collector, it is non-deterministic.

4. Dispose() has to be implemented in classes implementing IDispose interface.

5. Its the right place for freeing-up unmanaged resources like file, handles, and connections etc.

6. Dispose() method is called explicitely in the code itself.

7. Dispose() method is automatically called (for objects which implement IDispose), when used in a "using" statement.

Still hungry..... http:// forums . asp . net/p/466400/593963 . aspx#593963

----V V----
Regards,
Vikas Vaidya
This is reply of vikasvaidya to the previous question. Both the threads are moved to proper forum.
Reply With Quote
  #3 (permalink)  
Old 02-13-2008
Junior Member
 
Join Date: Feb 2008
Location: bangalore
Posts: 18
Thanks: 0
Thanked 2 Times in 1 Post
venkat.rbs is on a distinguished road
Re: dispose,finalize

Quote:
Originally Posted by debasisdas View Post
This is reply of vikasvaidya to the previous question. Both the threads are moved to proper forum.
Thanks allot vidya for clarifying the dipose and finalize.........
Reply With Quote
  #4 (permalink)  
Old 02-13-2008
Junior Member
 
Join Date: Feb 2008
Location: bangalore
Posts: 18
Thanks: 0
Thanked 2 Times in 1 Post
venkat.rbs is on a distinguished road
Re: dispose,finalize

plz let me know diff between public assembly and satilite assembly....
Reply With Quote
Reply

  Geeks Talk > Software Development > VB.NET


Thread Tools
Display Modes


Similar Threads

Thread Thread Starter Forum Replies Last Post
Need more information on finalize method. TigerElango Java 2 08-16-2007 09:06 AM


All times are GMT -4. The time now is 06:02 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Copyright © 2008 GeekInterview.com. All Rights Reserved