In the UML notation, parameterized (generic) classes are represented by

  1. the normal class representation with a dotted arrow pointing at the template parameter classes

  2. the normal class representation but shaded grey.

  3. the normal class representation with a dotted outline and the names of its parameter classes listed on the top right-hand corner.

  4. the normal class representation with a rectangular box in its top left-hand corner.

  5. Its a trick question - parameterized classes can't be specified in the UML notation.


Correct Option: C

AI Explanation

To answer this question, you need to understand how parameterized (generic) classes are represented in UML notation. Let's go through each option to understand why it is correct or incorrect:

Option A) The normal class representation with a dotted arrow pointing at the template parameter classes - This option is incorrect. In UML notation, a dotted arrow pointing at other classes typically represents an association or dependency relationship, not a parameterized class.

Option B) The normal class representation but shaded grey - This option is incorrect. In UML notation, shading is typically used to represent different levels of visibility or access, not to indicate a parameterized class.

Option C) The normal class representation with a dotted outline and the names of its parameter classes listed on the top right-hand corner - This option is correct. In UML notation, a parameterized class is represented by the normal class representation with a dotted outline and the names of its parameter classes listed on the top right-hand corner.

Option D) The normal class representation with a rectangular box in its top left-hand corner - This option is incorrect. In UML notation, a rectangular box in the top left-hand corner of a class is typically used to represent a stereotype, not a parameterized class.

Option E) It's a trick question - parameterized classes can't be specified in the UML notation - This option is incorrect. Parameterized classes can indeed be specified in UML notation using the representation mentioned in option C.

The correct answer is C. This option is correct because it accurately represents a parameterized (generic) class in UML notation.

Find more quizzes: