@@ -0,0 +1,1133 @@
+// --------------------- %E5%AE%9E%E7%8E%B0%E5%8C%96%E8%A7%92%E8%89%B2%E5%92%8C%E5%85%B7%E4%BD%93%E5%AE%9E%E7%8E%B0%E5%8C%96%E8%A7%92%E8%89%B2%0A%0Apublic interface Implementor %7B%0A    void doSomething();%0A    void doAnything();%0A%7D%0A%0Apublic class ImplementorImpl implements Implementor %7B%0A    public void doSomething() %7B%0A        System.out.println(%22ImplementorImpl doSomething...%22);%0A    %7D%0A%0A    public void doAnything() %7B%0A        System.out.println(%22ImplementorImpl doAnything...%22);%0A    %7D%0A%7D%0A%0A// --------------------- %E6%8A%BD%E8%B1%A1%E5%8C%96%E8%A7%92%E8%89%B2%E5%92%8C%E5%85%B7%E4%BD%93%E6%8A%BD%E8%B1%A1%E5%8C%96%E8%A7%92%E8%89%B2%0A%0Apublic abstract class Abstraction %7B%0A    Implementor implementor;%0A%0A    public Abstraction(Implementor implementor) %7B%0A        this.implementor = implementor;%0A    %7D%0A%0A    public void request() %7B%0A        implementor.doSomething();%0A    %7D%0A%7D%0A%0Apublic class ConcreteAbstraction extends Abstraction %7B%0A    public ConcreteAbstraction(Implementor implementor) %7B%0A        super(implementor);%0A    %7D%0A%0A    public void request() %7B%0A        implementor.doSomething();%0A        implementor.doAnything();%0A    %7D%0A%7D%0A%0A// --------------------- test code%0A%0Apublic static void main(String%5B%5D args) %7B%0A    Implementor implementor = new ImplementorImpl();%0A    Abstraction abstraction = new ConcreteAbstraction(implementor);%0A%0A    abstraction.request();%0A%7D

add bridge pattern