java常用集合框架关系

一.综合总图

1.所有集合类都位于java.util包下。

2.Java的集合类主要由两个接口派生而出:Collection和Map

3.Collection和Map是Java集合框架的根接口,这两个接口又包含了一些子接口或实现类。

总图

 

二.List

public interface Collection<E> extends Iterable<E>
public interface List<E> extends Collection<E>
public class ArrayList<E> extends AbstractList<E>
        implements List<E>, RandomAccess, Cloneable, java.io.Serializable
public class Vector<E> extends AbstractList<E>
    implements List<E>, RandomAccess, Cloneable, java.io.Serializable
public class LinkedList<E> extends AbstractSequentialList<E>
    implements List<E>, Deque<E>, Cloneable, java.io.Serializable
public interface Deque<E> extends Queue<E>
public abstract class AbstractSequentialList<E> extends AbstractList<E>

 

public abstract class AbstractList<E> extends AbstractCollection<E> implements List<E> 

 

public abstract class AbstractCollection<E> implements Collection<E>

 

 

关系图

 

 

Set

 

public class HashSet<E>  extends AbstractSet<E>
    implements Set<E>, Cloneable, java.io.Serializable

 

public class TreeSet<E> extends AbstractSet<E>
    implements NavigableSet<E>, Cloneable, java.io.Serializable
public class LinkedHashSet<E>
    extends HashSet<E>
    implements Set<E>, Cloneable, java.io.Serializable 
public interface NavigableSet<E> extends SortedSet<E>
public interface SortedSet<E> extends Set<E>

 

Map

public class HashMap<K,V> extends AbstractMap<K,V>
    implements Map<K,V>, Cloneable, Serializable
public class TreeMap<K,V>
    extends AbstractMap<K,V>
    implements NavigableMap<K,V>, Cloneable, java.io.Serializable
public class LinkedHashMap<K,V>
    extends HashMap<K,V>
    implements Map<K,V>
public class Hashtable<K,V>
    extends Dictionary<K,V>
    implements Map<K,V>, Cloneable, java.io.Serializable {
public
class Properties extends Hashtable<Object,Object> {
public abstract class AbstractMap<K,V> implements Map<K,V>
public interface NavigableMap<K,V> extends SortedMap<K,V>
public interface SortedMap<K,V> extends Map<K,V>

 

posted @ 2019-08-01 19:53  Rooker  阅读(397)  评论(0编辑  收藏  举报