O'Reilly logo

SAMS Teach Yourself C++ in 10 Minutes SECOND EDITION by Jesse Liberty

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

The User Interface in an Object

anExternalInterface takes care of everything in the user interface. However, for this version of the implementation, the code for restoring the calculator state from a saved tape has been removed. As mentioned in the previous lesson, this code will be reintroduced in Lesson 22.

anExternalInterface now contains everything involving communication with the outside world. None of the other classes (except aController, which always sends the SelfTest() results to cout or cerr) communicates with the outside world. Listing 20.3 shows anExternalInterface's header file.

Listing 20.3. anExternalInterface Header
 1: #ifndef ExternalInterfaceModuleH 2: #define ExternalInterfaceModuleH 3: 4: #include "RequestModule.h" 5: ...

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