Chapter 13. Properties

After completing this chapter, you will be able to:

  • Describe what properties are.

  • Explain how properties are supported by C++/CLI.

  • Implement properties.

Properties have been available in some programming languages—such as Microsoft Visual Basic—for some time, but the Microsoft .NET Framework has added support for them into Microsoft Intermediate Language (MSIL) so that they can be easily implemented in any .NET programming language. You’ll see in this chapter that properties can often lead to a more natural style of programming without sacrificing robustness or violating the principles of object-oriented programming.

What are properties?

It is a long-accepted principle of object-oriented programming that it’s a bad idea to give ...

Get Microsoft Visual C++/CLI Step by Step now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.