在这篇文章里,我们关注Java中的集合(Collection)。集合是编程语言中基础的一部分,Java自JDK早期,就引入了Java Collection Framework。设计JCF的那个人,后来还写了一本书,叫《Effective Java》。

  Java中的集合主要集中在2部分,一部分是java.util包中,一部分是java.util.concurrent中,后者是在前者的基础上,定义了一些实现了同步功能的集合。

  这篇文章主要关注java.util下的各种集合对象。Java中的集合对象可以粗略的分为3类:List、Set和Map。对应的UML图如下(包括了java.util下大部分的集合对象):

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAA/cAAAHHCAIAAAB1AT8cAAAgAElEQVR4nOydP4jkWpveFTXfhTU0a+/agYNebC0Nn/mozG2QYRKbASetTTxhgzDczI1RMBtNsIjrxHRScKOlA7FcZ0MFZiKjcJKCxtGgaBxVbzZBBR0eB4/r5VypVHWk0p/z5/kFTZd0JJ33Pa+OHr06OooUIYQQQkZltVpFPrJarZZ2LSHElGjpChBCCCG+EUV+Xl59tYsQL4mYbyB+wEgmhNhD5Kka9tUuQrwk8vWM9dUu0oWvLe6rXYT4ja9nrq92EeIlVPnEE3xtcV/tIsRvBpy56/V6v98PPmKe50mSbDabwXswgT0SIQ6xjMqv67qu60kPwZ4oNBjJhBB7OH3mHlXzXQK9KIr1en32iHEcG9btEtgjEeIQQ1R+XddZlnWtOrt5VVVJkhRF0fe4vWBPFBoDWrwsy7Isj65iJBNCLqHrzN3tdlmW5XkuS4qiSNNUKZXn+W6322w2ZVlmWYbr7H6/T9M0TVMI/c1mk6apXIKzLFuv11gbx3FRFPv9HkuyLJN+LMuyNE1xF6Hvoa7rJEn0bvBsn8YeiRCHOKPyd7tdI+WAXmO32x0tb5JLKIpigDCqqqpdjROwJwqNYZHcBSOZEHIJ7TMX+j5NU+kEiqLQRXaSJNvtFgt3u916vYYWz/M8z3M8OcT9wHa7xT9xHK/X6+12u91u4zjebrdKKeywLEuUSdMUSzabTXsP7WqUZXlC67NHIsQhOlW+9EeyBB2B3tEkSYKBgEhLZFkWRVGapnVdowdJ0xSr0Fuh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8AABksMJ5qIYA1brmodo9Uj4AADJY4TxUQ4BqXfNQ7R4pHwAAGaxwHuv1OlG0Xq+Xbu0Ni3AqEtE0rFoXAACscAD8IrywAQDgpv0HL28zvelOE2gAAAAASUVORK5CYII=" alt="" width="738" height="368" />

  (这张图经过缩放已经变形,完整清晰版图片请参见:http://files.cnblogs.com/wing011203/java_collection_structure.zip,解压缩后就可以看到未经缩放的版本。)

  Collection概述

  Java集合中的List和Set都从Collection出来,它是一个学习集合很不错的入口,它包含了集合中通常需要有的操作:

  • 添加元素:add/addAll
  • 清空集合:clear
  • 删除元素:remove/removeAll
  • 判断集合中是否包含某元素:contains/containsAll
  • 判断集合是否为空:isEmpty
  • 计算集合中元素的个数:size
  • 将集合转换为数组:toArray
  • 获取迭代器:iterator

  我们来看一个简单的例子,下面的代码会返回一个集合,集合中的元素是随机生成的整数:

 
 private static Collection initCollection()
{
Collection<Integer> collection = new ArrayList<Integer>();
Random r = new Random();
for (int i = 0 ; i < 5; i++)
{
collection.add(new Integer(r.nextInt(100)));
} return collection;
}
 

  在对集合进行操作的过程中,遍历是一个经常使用的操作,我们可以使用两种方式对集合进行遍历:

  1) 使用迭代器对集合进行遍历。正如上面描述Collection接口时所说,所有集合都会有一个迭代器,我们可以用它来遍历集合。

 
 private static void accessCollectionByIterator(Collection<Integer> collection)
{
Iterator<Integer> iterator = collection.iterator();
System.out.println("The value in the list:");
while(iterator.hasNext())
{
System.out.println(iterator.next());
}
}
 

  2)使用foreach遍历集合。

 
 private static void accessCollectionByFor(Collection<Integer> collection)
{
System.out.println("The value in the list:");
for(Integer value : collection)
{
System.out.println(value);
}
}
 

  List

  Java中的List是对数组的有效扩展,它是这样一种结构,如果不使用泛型,它可以容纳任何类型的元素,如果使用泛型,那么它只能容纳泛型指定的类型的元素。和数组相比,List的容量是可以动态扩展的。

  List中的元素是可以重复的,里面的元素是“有序”的,这里的“有序”,并不是排序的意思,而是说我们可以对某个元素在集合中的位置进行指定。

  List中常用的集合对象包括:ArrayList、Vector和LinkedList,其中前两者是基于数组来进行存储,后者是基于链表进行存储。其中Vector是线程安全的,其余两个不是线程安全的。

  List中是可以包括null的,即使是使用了泛型。

  ArrayList可能是我们平时用到的最多的集合对象了,在上述的示例代码中,我们也是使用它来实例化一个Collection对象,在此不再赘述。

  Vector

  Vector的示例如下,首先我们看如何生成和输出Vector:

 
 private static void vectorTest1()
{
List<Integer> list = new Vector<Integer>();
for (int i = 0 ; i < 5; i++)
{
list.add(new Integer(100));
}
list.add(null);
System.out.println("size of vector is " + list.size());
System.out.println(list);
}
 

  它的元素中,既包括了重复元素,也包括了null,输出结果如下:

size of vector is 6
[100, 100, 100, 100, 100, null]

  下面的示例,演示了Vector中的一些常用方法:

 
 private static void vectorTest2()
{
Vector<Integer> list = new Vector<Integer>();
Random r = new Random();
for (int i = 0 ; i < 10; i++)
{
list.add(new Integer(r.nextInt(100)));
}
System.out.println("size of vector is " + list.size());
System.out.println(list);
System.out.println(list.firstElement());
System.out.println(list.lastElement());
System.out.println(list.subList(3, 8));
List<Integer> temp = new ArrayList<Integer>();
for(int i = 4; i < 7; i++)
{
temp.add(list.get(i));
}
list.retainAll(temp);
System.out.println("size of vector is " + list.size());
System.out.println(list);
}
 

  它的输出结果如下:

 
size of vector is 10
[39, 41, 20, 9, 29, 32, 54, 12, 94, 82]
39
82
[9, 29, 32, 54, 12]
size of vector is 3
[29, 32, 54]
 

  LinkedList

  LinkedList使用链表来存储数据,它的示例代码如下:

 
 private static void linkedListTest1()
{
LinkedList<Integer> list = new LinkedList<Integer>();
Random r = new Random();
for (int i = 0 ; i < 10; i++)
{
list.add(new Integer(r.nextInt(100)));
}
list.add(null);
System.out.println("size of linked list is " + list.size());
System.out.println(list);
System.out.println(list.element());
System.out.println(list.getFirst());
System.out.println(list.getLast());
System.out.println(list.peek());
System.out.println(list.peekFirst());
System.out.println(list.peekLast());
System.out.println(list.poll());
System.out.println(list.pollFirst());
System.out.println(list.pollLast());
System.out.println(list.pop());
list.push(new Integer(100));
System.out.println("size of linked list is " + list.size());
System.out.println(list);
}
 

  这里列出了LinkedList常用的各个方法,从方法名可以看出,LinkedList也可以用来实现栈和队列。

  输出结果如下:

 
size of linked list is 11
[17, 21, 5, 84, 19, 57, 68, 26, 27, 47, null]
17
17
null
17
17
null
17
21
null
5
size of linked list is 8
[100, 84, 19, 57, 68, 26, 27, 47]
 

  Set

  Set 和List类似,都是用来存储单个元素,单个元素的数量不确定。但Set不能包含重复元素,如果向Set中插入两个相同元素,那么后一个元素不会被插入。

  Set可以大致分为两类:不排序Set和排序Set,不排序Set包括HashSet和LinkedHashSet,排序Set主要指TreeSet。其中HashSet和LinkedHashSet可以包含null。

  HashSet

  HashSet是由Hash表支持的一种集合,它不是线程安全的。

  我们来看下面的示例,它和Vector的第一个示例基本上是相同的:

 
 private static void hashSetTest1()
{
Set<Integer> set = new HashSet<Integer>(); for (int i = 0; i < 3; i++)
{
set.add(new Integer(100));
}
set.add(null); System.out.println("size of set is " + set.size());
System.out.println(set);
}
 

  这里,HashSet中没有包含重复元素,但包含了null,和Vector不同,这里的输出结果如下

size of set is 2
[null, 100]

  对于HashSet是如何判断两个元素是否是重复的,我们可以深入考察一下。Object中也定义了equals方法,对于HashSet中的元素,它是根据equals方法来判断元素是否相等的,为了证明这一点,我们可以定义个“不正常”的类型:

 
 class MyInteger
{
private Integer value; public MyInteger(Integer value)
{
this.value = value;
} public String toString()
{
return String.valueOf(value);
} public int hashCode()
{
return 1;
} public boolean equals(Object obj)
{
return false;
}
}
 

  可以看到,对于MyInteger来说,对于任意两个实例,我们都认为它是不相等的。

  下面是对应的测试方法:

 
 private static void hashSetTest2()
{
Set<MyInteger> set = new HashSet<MyInteger>(); for (int i = 0; i < 3; i++)
{
set.add(new MyInteger(100));
} System.out.println("size of set is " + set.size());
System.out.println(set);
}
 

  它的输出结果如下:

size of set is 3
[100, 100, 100]

  可以看到,现在HashSet里有“重复”元素了,但对于MyInteger来说,它们不是“相同”的。

  TreeSet

  TreeSet是支持排序的一种Set,它的父接口是SortedSet。

  我们首先来看一下TreeSet都有哪些基本操作:

 
 private static void treeSetTest1()
{
TreeSet<Integer> set = new TreeSet<Integer>(); Random r = new Random();
for (int i = 0 ; i < 5; i++)
{
set.add(new Integer(r.nextInt(100)));
} System.out.println(set);
System.out.println(set.first());
System.out.println(set.last());
System.out.println(set.descendingSet());
System.out.println(set.headSet(new Integer(50)));
System.out.println(set.tailSet(new Integer(50)));
System.out.println(set.subSet(30, 60));
System.out.println(set.floor(50));
System.out.println(set.ceiling(50));
}
 

  它的输出结果如下:

 
[8, 42, 48, 49, 53]
8
53
[53, 49, 48, 42, 8]
[8, 42, 48, 49]
[53]
[42, 48, 49, 53]
49
53
 

  TreeSet中的元素,一般都实现了Comparable接口,默认情况下,对于Integer来说,SortedList是采用升序来存储的,我们也可以自定义Compare方式,例如以降序的方式来存储。

  下面,我们首先重新定义Integer:

 
 class MyInteger2 implements Comparable
{
public int value; public MyInteger2(int value)
{
this.value = value;
} public int compareTo(Object arg0)
{
MyInteger2 temp = (MyInteger2)arg0;
if (temp == null) return -1;
if (temp.value > this.value)
{
return 1;
}
else if (temp.value < this.value)
{
return -1;
}
return 0;
} public boolean equals(Object obj)
{
return compareTo(obj) == 0;
} public String toString()
{
return String.valueOf(value);
}
}
 

  下面是测试代码:

 
 private static void treeSetTest2()
{
TreeSet<Integer> set1 = new TreeSet<Integer>();
TreeSet<MyInteger2> set2 = new TreeSet<MyInteger2>();
Random r = new Random();
for (int i = 0 ; i < 5; i++)
{
int value = r.nextInt(100);
set1.add(new Integer(value));
set2.add(new MyInteger2(value));
}
System.out.println("Set1 as below:");
System.out.println(set1);
System.out.println("Set2 as below:");
System.out.println(set2);
}
 

  代码的运行结果如我们所预期的那样,如下所示:

Set1 as below:
[13, 41, 42, 45, 61]
Set2 as below:
[61, 45, 42, 41, 13]

  Map

  Map中存储的是“键值对”,和Set类似,Java中的Map也有两种:排序的和不排序的,不排序的包括HashMap、Hashtable和LinkedHashMap,排序的包括TreeMap。

  非排序Map

  HashMap和Hashtable都是采取Hash表的方式进行存储,HashMap不是线程安全的,Hashtable是线程安全的,我们可以把HashMap看做是“简化”版的Hashtable。

  HashMap是可以存储null的,无论是对Key还是对Value。Hashtable是不可以存储null的。

  无论HashMap还是Hashtable,我们观察它的构造函数,就会发现它可以有两个参数:initialCapacity和 loadFactor,默认情况下,initialCapacity等于16,loadFactor等于0.75。这和Hash表中可以存放的元素数目有 关系,当元素数目超过initialCapacity*loadFactor时,会触发rehash方法,对hash表进行扩容。如果我们需要向其中插入 过多元素,需要适当调整这两个参数。

  我们首先来看HashMap的示例:

 
 private static void hashMapTest1()
{
Map<Integer,String> map = new HashMap<Integer, String>(); map.put(new Integer(1), "a");
map.put(new Integer(2), "b");
map.put(new Integer(3), "c"); System.out.println(map);
System.out.println(map.entrySet());
System.out.println(map.keySet());
System.out.println(map.values());
}
 

  这会输出HashMap里的元素信息,如下所示。

{1=a, 2=b, 3=c}
[1=a, 2=b, 3=c]
[1, 2, 3]
[a, b, c]

  下面的示例是对null的演示:

 
 private static void hashMapTest2()
{
Map<Integer,String> map = new HashMap<Integer, String>(); map.put(null, null);
map.put(null, null);
map.put(new Integer(4), null);
map.put(new Integer(5), null); System.out.println(map);
System.out.println(map.entrySet());
System.out.println(map.keySet());
System.out.println(map.values());
}
 

  执行结果如下:

{null=null, 4=null, 5=null}
[null=null, 4=null, 5=null]
[null, 4, 5]
[null, null, null]

  接下来我们演示Hashtable,和上述两个示例基本上完全一样(代码不再展开):

 
 private static void hashTableTest1()
{
Map<Integer,String> table = new Hashtable<Integer, String>(); table.put(new Integer(1), "a");
table.put(new Integer(2), "b");
table.put(new Integer(3), "c"); System.out.println(table);
System.out.println(table.entrySet());
System.out.println(table.keySet());
System.out.println(table.values());
} private static void hashTableTest2()
{
Map<Integer,String> table = new Hashtable<Integer, String>(); table.put(null, null);
table.put(null, null);
table.put(new Integer(4), null);
table.put(new Integer(5), null); System.out.println(table);
System.out.println(table.entrySet());
System.out.println(table.keySet());
System.out.println(table.values());
}
 

  执行结果如下:

 
{3=c, 2=b, 1=a}
[3=c, 2=b, 1=a]
[3, 2, 1]
[c, b, a]
Exception in thread "main" java.lang.NullPointerException
at java.util.Hashtable.put(Unknown Source)
at sample.collections.MapSample.hashTableTest2(MapSample.java:61)
at sample.collections.MapSample.main(MapSample.java:11)
 

  可以很清楚的看到,当我们试图将null插入到hashtable中时,报出了空指针异常。

  排序Map

  排序Map主要是指TreeMap,它对元素增、删、查操作时的时间复杂度都是O(log(n))。它不是线程安全的。

  它的特点和TreeSet非常像,这里不再赘述。

Java回顾之集合的更多相关文章

  1. Java回顾之Spring基础

    第一篇:Java回顾之I/O 第二篇:Java回顾之网络通信 第三篇:Java回顾之多线程 第四篇:Java回顾之多线程同步 第五篇:Java回顾之集合 第六篇:Java回顾之序列化 第七篇:Java ...

  2. java回顾(项目前期的基本准备)

    一.     基础回顾 1   集合 1.1 集合的类型与各自的特性 ---|Collection: 单列集合 ---|List: 有存储顺序, 可重复 ---|ArrayList:  数组实现, 查 ...

  3. 《回炉重造 Java 基础》——集合(容器)

    整体框架 绿色代表接口/抽象类:蓝色代表类. 主要由两大接口组成,一个是「Collection」接口,另一个是「Map」接口. 前言 以前刚开始学习「集合」的时候,由于没有好好预习,也没有学好基础知识 ...

  4. Java 中的集合接口——List、Set、Map

    Java 中的集合接口——List.Set.Map 什么叫集合:集合就是Java API所提供的一系列类的实例,可以用于动态存放多个对象.这跟我们学过的数组差不多,那为什么我们还要学集合,我们看看数组 ...

  5. Java中的集合框架

    概念与作用 集合概念 现实生活中:很多事物凑在一起 数学中的集合:具有共同属性的事物的总体 java中的集合类:是一种工具类,就像是容器,储存任意数量的具有共同属性的对象 在编程时,常常需要集中存放多 ...

  6. 实现java 中 list集合中有几十万条数据,每100条为一组取出

    解决"java 中 list集合中有几十万条数据,每100条为一组取出来如何实现,求代码!!!"的问题. 具体解决方案如下: /** * 实现java 中 list集合中有几十万条 ...

  7. Java Hour 13 集合基础

    有句名言,叫做10000小时成为某一个领域的专家.姑且不辩论这句话是否正确,让我们到达10000小时的时候再回头来看吧. 本文作者Java 现经验约为13 Hour,请各位不吝赐教. Java 中的集 ...

  8. java中对集合对象list的几种循环访问

    java中对集合对象list的几种循环访问的总结如下 1 经典的for循环 public static void main(String[] args) { List<String> li ...

  9. 菜鸟日记之 java中的集合框架

    java中的集合框架图 如图所示:java中的集合分为两种Collection和Map两种接口 可分为Collection是单列集合和Map的双列集合 Collection单列集合:继承了Iterat ...

随机推荐

  1. 【转载】排查Linux机器是否已经被入侵

          背景信息:以下情况是在CentOS 6.9的系统中查看的,其它Linux发行版类似 1.入侵者可能会删除机器的日志信息,可以查看日志信息是否还存在或者是否被清空,相关命令示例: [root ...

  2. SQL---->mySQl卸载for mac

    因为装的时候弄坏了 先来学习下怎么卸载吧,如下输入终端就好了 cd ~/ sudo rm /usr/local/mysql sudo rm -rf /usr/local/mysql* sudo rm ...

  3. Mongo副本集的配置以及php node.js连接使用副本集

    最近弄了下mongodb的副本集, 首先说下没有认证情况的副本集,相对比较简单,因为环境有限,我在同一台服务器上做了模拟. --rest参数是打开web监控页面,比如我们这里监听37017端口,则打开 ...

  4. python调用C++之pybind11入门(相互调用)

    python调用C/C++有不少的方法,如boost.python, swig, ctypes, pybind11等,这些方法有繁有简,而pybind11的优点是对C++ 11支持很好,API比较简单 ...

  5. Python开发【Django】:CMDB基础

    浅谈ITIL TIL即IT基础架构库(Information Technology Infrastructure Library, ITIL,信息技术基础架构库)由英国政府部门CCTA(Central ...

  6. 使用git和gitlab进行协同开发流程

    一.基本概念 1.仓库(Repository) ①源仓库(线上版本库) 在项目的开始,项目的发起者构建起一个项目的最原始的仓库,称为origin. 源仓库的有两个作用: 1.汇总参与该项目的各个开发者 ...

  7. 把大象装进冰箱的N种方法

    作者:折剑头链接:https://www.zhihu.com/question/49214119/answer/115728034来源:知乎著作权归作者所有.商业转载请联系作者获得授权,非商业转载请注 ...

  8. [LeetCode] 83. Remove Duplicates from Sorted List_Easy tag: Linked List

    Given a sorted linked list, delete all duplicates such that each element appear only once. Example 1 ...

  9. 26种基于PHP的开源博客系统

    26种基于PHP的开源博客系统 来源:本站原创 PHP学习笔记 以下列举的PHP开源Blog系统中,除了我们熟知的WordPress之外,大多都没有使用过,其中一些已经被淘汰,或者有人还在使用.除了做 ...

  10. Redis在Linux下的安装与配置

    Redis是一个开源的使用ANSI C语言编写.支持网络.可基于内存亦可持久化的日志型.Key-Value数据库,并提供多种语言的API. Redis是 NoSQL技术阵营中的一员. 说到NoSQL, ...