Java collections framework: Difference between revisions

Content deleted Content added
Add subsection
AbstractSet: Add details about AbstractSet
Line 168:
{{java|AbstractSet}} is a ''skeletal implementation'' for the {{java|Set}} interface.{{sfn|Bloch|2018|loc=Chapter §4 Item 20: Prefer interfaces to abstract classes|pp=99-103}}
 
There are variousDirect subclasses of {{java|AbstractSet}} include {{java|ConcurrentSkipListSet}}, {{java|CopyOnWriteArraySet}}, {{java|EnumSet}}, {{java|HashSet}} and {{java|TreeSet}}.
 
=====HashSet class=====
Line 174:
 
======LinkedHashSet class======
The <code>java.util.LinkedHashSet</code> class extends {{java|HashSet}} by creating a doubly linked list that links all of the elements by their insertion order. This ensures that the iteration order over the <code>Set</code> is predictable.
 
===SortedSet interface===