UdaCity学习Java记录(2)接口、多态、泛型
产品接口,有location抽象方法public interface Production { public String location(); }交通工具接口,有getType、getSpeed、getColor抽象方法public interface Vehicle { public String getType(); public String getS...
产品接口,有location抽象方法public interface Production { public String location(); }交通工具接口,有getType、getSpeed、getColor抽象方法public interface Vehicle { public String getType(); public String getS...
Person 类public class Person { private String firstName; private String lastName; public Person(String firstName, String lastName) { super(); this.firstName = firstName;...