It would be really strange if you would have a class Cat that extends class Dog. If you do that, you're saying that a Cat is a special kind of Dog. My cat will certainly disagree with that... So, the second half of your example is a little strange
I think I needed to clarify the above, what precisely I meant. I'm not saying that Cat extends Dog! I meant, Given the below, as an example
About the <? super Animal> use case, I meant that, say, a "collection
is already pre-filled with DOG instances". Suppose that another method "addMoreAnimals" that gets this collection as a parameter has the "potential" to add any subtype of Animal, by mistake, to the pre filled DOG collection. If one wants to maintain the sanity of the above collection and YET ALLOW that another "addMoreAnimals" method to ONLY
add Dogs in a guaranteed way, then that method's signature needs to be
The reason is that if you just had "addMoreAnimals(List<Animal>...), then this signature will allow the method to add ALSO Cat instances. Does that make sense?