What difference would it make if Java Collection Interface has addAll method signature like this
<T extends E> boolean addAll(Collection<T> c);
rather than
boolean addAll(Collection<? extends E> c);?
Thanks
-Abidi
In this case, having <?> or <T> is equivalent for users of addAll.
I think that the former notation was used for clarity, because using <T> makes the signature of addAll more complicated.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With