Advanced Features in Java: Working with Sets In Java
Java SE 13
| Expert
- 11 videos | 1h 22m 27s
- Includes Assessment
- Earns a Badge
In this course, you'll explore the Set interface and the different Set collections available in Java. You'll learn how the Java Set interface extends Collection, and how it is used to define unordered collections in which duplicates are not allowed. You'll discover common set operations such as union, difference, intersection, and equality, as well as how these are influenced heavily by the implementation of .equals and .hashCode in the objects contained within the set. You'll cover four implementations of the Set interface - HashSet, LinkedHashSet, EnumSet, and TreeSet. Finally, you'll learn the correct implementations of the .hashCode, .equals, and .compareTo methods of user-defined objects that are to be stored in Sets.
WHAT YOU WILL LEARN
-
discover the key concepts covered in this coursecreate a HashSet object and invoke multiple methods on it, and also correctly override the .hashCode and .equals method of the contained classdescribe how the HashSet behaves with duplicates and how overridden versions of the .equals and the .hashCode methods influence this behaviorrecognize the different types of sets and how they all extend the Set, Collection, and Iterable interfacesdifferentiate between methods used to compute set union, difference, intersection, and equality operationsanalyze the performance characteristics of LinkedHashSets, TreeSets, and HashSets
-
recognize how and why EnumSets should be used to represent categorical datadescribe how different implementations of the Set interface differ in their notions of set ordercreate a TreeSet and sort it using various custom comparatorscreate a TreeSet that stores custom objects without also creating a custom comparatorsummarize the key concepts covered in this course
IN THIS COURSE
-
1.Course Overview2m 30sUP NEXT
-
2.Introduction to HashSets9m 33s
-
3.HashSets and Duplicates7m 1s
-
4.Different Types of Sets10m 19s
-
5.Properties of Sets9m 11s
-
6.Iteration over Sets8m 20s
-
7.Using EnumSets6m 35s
-
8.Order of Set Elements7m 22s
-
9.TreeSets and Comparators9m 29s
-
10.TreeSets, Custom Objects, and Custom Comparators9m 56s
-
11.Course Summary2m 13s
EARN A DIGITAL BADGE WHEN YOU COMPLETE THIS COURSE
Skillsoft is providing you the opportunity to earn a digital badge upon successful completion on some of our courses, which can be shared on any social network or business platform.
Digital badges are yours to keep, forever.