4、alvoidRequest()=0;};//classAdapterclassAdapter:publicTarget{public:virtualvoidRequest(){_adaptee.SpecialRequest();}private:Adaptee_adaptee;};}客户端代码:{usingnamespaceDesignPattern_Adapter;Target*p=newAdapter();p->Request();//实际上调用的是Adaptee::SpecialRequest()} 六、实例 (1)STL中的ClassAdapter S