public class BusOnStreet extends Street{
public void run(){System.out.println("公共汽车在街道上行驶");}
}
传统做法通过继承来实现
结构图:
上一页 [1] [2]
责任编辑:cyth