what is finalize() and dispose() methods?

what is the difference between these two?

  • Babita
  • 13 Oct 2022
  • 606 Views
  • 4 Answers
Your Answer

The main difference between dispose() and finalize() is that the method dispose() has to be explicitly invoked by the user whereas, the method finalize() is invoked by the garbage collector, just before the object is destroyed.

C Sharp Dot Net

Didn't get the answer.
Contact people of Talent-C Sharp Dot Net directly by clicking here