O'Reilly logo

Microsoft Windows Communication Foundation Hands-on! Beta Edition by Craig McMurtry, Nigel Watling, Marc Mercuri

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 2. The Fundamentals

In This Chapter

Background

Dealing with something as an integrated whole is self-evidently easier than having to understand and manipulate all of it parts. Thus, to make programming easier, it is commonplace to define classes that serve as integrated wholes, keeping their constituents hidden. Doing so is called encapsulation, which is characteristic of what is known as object-oriented programming.

The C++ programming language provided syntax for encapsulation that proved very popular. In C++, one can write a class like this one:

class Stock { private: char symbol[30]; int number; double price; double value; void SetTotal() { this->value = this->number * this->price; } public: Stock(void); ~Stock(void); ...

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