适配器模式
'; }}//类适配器模式class Adapter implements Target{ private $adatee; public function __construct(Adatee $adatee){ $this->adatee = $adatee; } public function simpleMethod1(){ echo $this->adatee->simpleMethod1(); } public function simpleMethod2(){ echo $this->adatee->simpleMethod12(); }}//客户端接口class Client{ public static function main(){ $adapter = new Adapter(new Adatee()); $adapter->simpleMethod1(); }}Client::main();