<<< Pattern Three: Adapter | Index | Abstract adapter >>> |
Consider adapters when interfaces are quite similar.
class Adapter : public Base { public: // Base functions //... private: Done m_done; };//class Adapter
Or possibly:
class Adapter : public Base, private Done
Or build a two-way adapter, using multiple inheritance where both bases are public:
class Adapter : public Base, public Done
<<< Pattern Three: Adapter | Index | Abstract adapter >>> |