Dispose() and Finalize() methods
Specify the differences between the Dispose() and Finalize() methods.
Expert
CLR utilizes the Finalize and Dispose methods to execute garbage collection of run-time objects of .NET applications.
The Finalize () method is called automatically by runtime. CLR has garbage collector (GC), that periodically checks for objects in the heap which are no longer referenced by any of the object or program. It calls the Finalize method in order to free the memory utilized by these type of objects.
The Dispose () method is called manually by the programmer. Dispose is other method to evacuate the memory used by the object. The Dispose method required to be called explicitly in the code to dereference an object within the heap. The Dispose method can be invoked by the classes that implements the IDisposable interface.
What do you understand by Common Type System (CTS)?
Illustrate the various types of contract available in the WCF?
Explain the benefits of using the ADO.NET in .NET 4.0?
Specify the similarities between a class and a structure.
How one can implement the text box to display characters in the uppercase?
What is a behavior of the Web browser when it receives the invalid element?
Is it possible for users to define their own exceptions in code?
Can we enter more than single line in the TextBox control?
In what way we can display the icon during runtime on a StatusStrip control?
Explain the use of a CommandBuilder class?
18,76,764
1950685 Asked
3,689
Active Tutors
1454700
Questions Answered
Start Excelling in your courses, Ask an Expert and get answers for your homework and assignments!!