O'Reilly logo

Expert C# 5.0: with the .NET 4.5 Framework by Mohammad Rahman

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

CHAPTER 4

images

Methods

This chapter will discuss the following C# methods: instance, static, anonymous, and extension. In doing so, you’ll learn how the this keyword relates to these methods and how the CLR passes value for the this keyword used as parameter in runtime by examining data on the stack.

You will also explore how the anonymous method works when there is external variable reference in it and when there is no external variable referenced from it. Additionally, you will find out how the this keyword is used in both circumstances.

Finally, you will learn about the compile time and runtime behavior of the extension methods and how the C# compiler ...

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