Consider the HashSet and TreeSet classes of the standard library.
What abstract class do they extend? What interface types does that abstract class implement? Draw a class diagram
(1): HashSet
HashSet class has been extended from abstract class called "AbstractSet". AbstractSet class is an abstract class that has been implemented from interface named "Set".
UML diagram for HashSet is as follows:
(2): TreeSet
TreeSet is a class that has been directly extended from an interface named "NavigableSet", where NavigableSet has been extended from an interface named "SortedSet", where SortedSet has been extended from an interface named "Set"
UML diagram for TreeSet is as follows:
Mention in comments if any mistakes or errors are found. Thank you.
Get Answers For Free
Most questions answered within 1 hours.