摘要: public class TestUSB {public static void main(String[] args) { computer m=new computer(); m.dowork(new Flash()); phone p=new phone(); m.dowork(p); //实 阅读全文
posted @ 2017-05-11 23:43 为了八千块 阅读(148) 评论(0) 推荐(0) 编辑
摘要: interface Object { void action(); } //代理类 class ProxyObject implements Object { Object obj; public ProxyObject() { obj=new ObjectImpl(); System.out.Pr 阅读全文
posted @ 2017-05-11 23:09 为了八千块 阅读(108) 评论(0) 推荐(0) 编辑