学习java容器

来源:互联网 发布:剑网3重制版继承数据不 编辑:程序博客网 时间:2024/06/04 23:23

参考资料 http://wenku.baidu.com/view/7578858dcc22bcd126ff0c91.html
API http://developer.android.com/reference/java/util/Collection.html
Summary APIs already read:
Collection
Comparator
Deque
Interator
List
ListInterator
Map: -(v)get(k)  -()put(<k,v>)  -(set)keySet() -(Collection)values() -()remove(k)
set:does not allow duplicate element.
Quene:Queue implementationsgenerally do not allow insertionof null elements,
 Throws exceptionReturns special valueInsertadd(e)offer(e)Removeremove()poll()Examineelement()peek()
----------------------------------------
ArrayList:can add null。动态数组
All optional operations including adding, removing, and replacingelements are supported.
LinkedList:双链表
Vector:(具有同步机制,非常类似于ArrayList)

HashSet:可以加入null,
原创粉丝点击