小结

来源:互联网 发布:twrp备份文件提取数据 编辑:程序博客网 时间:2024/05/22 12:34

集合的使用:

接口的构造方法:

List(元素有序可以重复且不唯一)-ArrayList(不安全)、LinkedList(不安全)、Vector(安全);    

Set(元素无序不可重复且唯一)-HashSet(不安全)LinkedHashSet、TreeSet

接口用法:

增、插:add();

删:remove();

改:set();

查:contains();  equals();containsAll();isEmpty();iterator();retainAll(); size();  toArray();  listIterator();