What is the difference between parameterized class, multiobjects and Collections?

Asked

Viewed 411 times

0

Well, I know the concepts of each one. I just don’t know how to tell them apart. For example, a parameterized class is a class that is used to define other classes, and a Collection can be represented by a parameterized class. However, what is the difference between them? After all. in Java, a parameterized class is equivalent to a Collection. As for multiobjects, I also know that they can represent the many side in an association one for many, but I also cannot see the differences between these three concepts. If anyone can help me, I’d appreciate it!

1 answer

-2

A Collection can contain primitive types, such as ints.. The "multiobject" is a Collection with Generics, by default, every argument that is inside Generics has to be an Object, that is class, class that inherits from Object (in java) for example: List<String> or List<Suaclass>. Parameterized class I don’t know.

Source: Chapter 7 The Book of Bezerra

Browser other questions tagged

You are not signed in. Login or sign up in order to post.