O'Reilly logo

Applied Microsoft® .NET Framework Programming by Jeffrey Richter

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Resurrection

I’m sure you’d agree that finalization is fascinating. And there’s even more to it than what I’ve already described. You’ll notice that when an object requiring finalization is considered dead, the garbage collector forces the object back to life so that its Finalize method can be called. Then after its Finalize method is called, the object is permanently dead. To summarize: an object requiring finalization dies, lives, and then dies again. This very interesting phenomenon is called resurrection. Resurrection, as its name implies, allows an object to come back from the dead.

The act of preparing to call an object’s Finalize method is a form of resurrection. When the garbage collector places a reference to the object on the freachable ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required