Results 1 to 6 of 6

Thread: What is the finalize block in .net ?

  1. #1

  2. #2
    Registered pxljobs's Avatar
    Join Date
    Jul 2016
    Location
    Bangalore
    Posts
    290
    It will belong to object class,automatically called garbage collection mechanism object go out of scope also it is an slower methods not suitable for instant disposing object,it is an non deterministic function.

  3. #3
    Finalize method is used to perform cleanup operations on unmanaged resources held by the current object before the object is destroyed

  4. #4
    Registered
    Join Date
    Nov 2017
    Location
    Sao Paulo
    Posts
    159
    The Finalize method is used to perform cleanup operations on unmanaged resources held by the current object before the object is destroyed.

  5. #5
    Registered
    Join Date
    Oct 2016
    Posts
    270
    Object.Finalize method in .NET is typically used to clean and release unmanaged resources like OS files, window etc. Even though Garbage collector in .NET has the ability to determine the life time of such objects, however, with no knowledge how to clean them. The Finalize method allows an object to clean up such unmanaged resources when the garbage collector wishes to reclaim the memory. However, Finalize method should be avoided until necessary as it affects the performance because reclaiming the memory used by objects with Finalize methods requires at least two garbage collections.
    Best Android Training | Devops Training | SQL Server Training and many more IT courses.

  6. #6
    Registered
    Join Date
    Jan 2018
    Posts
    66
    The method is protected and therefore is accessible only through this class or through a derived class.

Similar Threads

  1. How to Block Skype?
    By MissMandy in forum General Chat
    Replies: 3
    Last Post: 07-08-2019, 04:40 AM
  2. Block Countries?
    By Todd W in forum General Management Issues
    Replies: 29
    Last Post: 12-13-2006, 02:39 PM
  3. Lay Out HELP writers BLOCK
    By izwar in forum HTML, CSS, Layout, and Design
    Replies: 3
    Last Post: 08-11-2006, 08:45 AM
  4. New Kid on the Block
    By Bricktowntom in forum Introductions
    Replies: 7
    Last Post: 04-10-2006, 06:24 AM
  5. Possible to block search engines...
    By deronsizemore in forum General Management Issues
    Replies: 5
    Last Post: 10-10-2005, 05:56 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •