This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "CellPhoneTextApp.h" | |
| class CellPhoneTextAppImpl; | |
| class IPhone8TextApp : public CellPhoneTextApp { | |
| public: | |
| IPhone8TextApp(CellPhoneTextAppImpl * impl); | |
| virtual ~IPhone8TextApp(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "GalaxyS8TextApp.h" | |
| #include <iostream> | |
| GalaxyS8TextApp::GalaxyS8TextApp(CellPhoneTextAppImpl * impl) | |
| : CellPhoneTextApp(impl) { | |
| } | |
| GalaxyS8TextApp::~GalaxyS8TextApp() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "CellPhoneTextApp.h" | |
| class CellPhoneTextAppImpl; | |
| class GalaxyS8TextApp : public CellPhoneTextApp { | |
| public: | |
| GalaxyS8TextApp(CellPhoneTextAppImpl * impl); | |
| virtual ~GalaxyS8TextApp(); | |
| virtual void Open(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "CellPhoneTextApp.h" | |
| #include "CellPhoneTextAppImpl.h" | |
| CellPhoneTextApp::CellPhoneTextApp(CellPhoneTextAppImpl * impl) | |
| : m_pImpl(impl) { | |
| } | |
| CellPhoneTextApp::~CellPhoneTextApp() { | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class CellPhoneTextAppImpl; | |
| class CellPhoneTextApp { | |
| public: | |
| CellPhoneTextApp(CellPhoneTextAppImpl * impl); | |
| virtual ~CellPhoneTextApp(); | |
| virtual void Open() = 0; | |
| virtual void Close() = 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int main() | |
| { | |
| ZooMember member(std::string("Nicklas")); | |
| ZooGuest guest(std::string("Bob")); | |
| Zoo zoo; | |
| ZooProxy zooProxy(&zoo); | |
| zooProxy.EnterZooEarly(&member); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ZooProxy::ZooProxy(Zoo * zoo) | |
| : m_pZoo(zoo) | |
| { | |
| } | |
| ZooProxy::~ZooProxy() { | |
| } | |
| void ZooProxy::EnterZooEarly(ZooPatron * patron) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class ZooProxy { | |
| public: | |
| ZooProxy(Zoo * zoo); | |
| virtual ~ZooProxy(); | |
| virtual void EnterZooEarly(ZooPatron * patron); | |
| virtual void AttendAnimalShow(ZooPatron * patron); | |
| private: | |
| Zoo * m_pZoo; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Zoo::Zoo() { | |
| } | |
| Zoo::~Zoo() { | |
| } | |
| void Zoo::EnterZooEarly(ZooPatron * patron) | |
| { | |
| std::cout << "Welcome, " << patron->GetName() << ", to our early access zoo hours\n"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class Zoo { | |
| public: | |
| Zoo(); | |
| virtual ~Zoo(); | |
| virtual void EnterZooEarly(ZooPatron * patron); | |
| virtual void AttendAnimalShow(ZooPatron * patron); | |
| }; |