Friday, November 15, 2013

Main important usable Terms in Collection classes / implementations...10/10


Below are most important terms that we forget regularly....

  • Synchronized - Vector, Hashtable
  • NonSynchronized - All remaining
  • Ordered - ArrayList, Vector, LinkedList, LinkedHashSet, LinkedHashMap
  • Sorted - TreeSet, TreeMap
  • Homogeneous elements - TreeSet, TreeMap
  • Heterogeneous elements - remaining all
  • Allow nulls - ArrayList, Vector, LinkedList, HashSet, LinkedHashSet, 
  • No nulls - TreeSet
  • Allow nullkeys - HashMap
  • No nullkeys - HashTable
  • Allow nullvalues - HashMap
  • No nullvalues - HashTable
  • Iterator - All List and Set implements, All Map implements keySet's
  • ListIterator - only List implements, 
  • Enumeration - legacy Vector, HashTable
  • toArray - All List, Set implements
*** Since List, Set implementations are the instance of Iterable interface, we can iterate them using for-each loop at any time. ***

No comments:

Post a Comment