#include <iostream> using namespace std; class subsys1 { public: subsys1(){} ~subsys1(){} void operation(){cout<<"subsys1"<<endl;} }; class subsys2 { public: subsys2(){} ~subsys2(){} void operation(){cout<<"subsys2"<<endl;} }; class subsys3 { public: subsys3(){} ~subsys3(){} void operation(){cout<<"subsys3"<<endl;} }; class facade { public: facade(){} ~facade(){} void mathod1() { sb1->operation(); sb2->operation(); } void mathod2() { sb2->operation(); sb3->operation(); } private: subsys1 *sb1; subsys2 *sb2; subsys3 *sb3; }; int main() { facade *fac=new facade; fac->mathod1(); fac->mathod2(); delete fac; system("pause"); return 0; }