I have found that the treeSet and HashSet extends AbstractSet and implements Cloneable and Serializable interfaces.
What happens if AbstractSet itself implements Cloneable and Serializable interfaces, so that The HashSet and TreeSet need not to implement separately?
Is it a design concern or is there any logic behind in doing so?
I appreciate your quick response..
It would mean that anybody else such as me who extended AbstractSet would be stuck with my implementation being serializable and cloneable whether I wanted or not. No doubt the designers wanted to provide the freedom not to do so.