What is true about UML stereotypes ?

2014

What is true about UML stereotypes ?

  1. A.

    Stereotype is used for extending the UML language.

  2. B.

    Stereotyped class must be abstract

  3. C.

    The stereotype indicates that the UML element cannot be changed

  4. D.

    UML profiles can be stereotyped for backward compatibility

Attempted by 262 students.

Show answer & explanation

Correct answer: A

Correct statement: "Stereotype is used for extending the UML language."

Explanation: Stereotypes are an extension mechanism in UML that let you add new semantic classifications and properties to existing UML metamodel elements.

  • How stereotypes work: They allow you to create domain-specific extensions by applying named stereotypes and tagged values to model elements (for example, applying a «service» stereotype to a class).

  • Stereotypes do not force abstractness: A stereotyped class can be concrete or abstract depending on the model; stereotypes add semantic information but do not inherently change the element's abstract/concrete status.

  • Stereotypes do not imply immutability: They annotate elements with additional meaning or properties. Restrictions on change are expressed using constraints, OCL, documentation, or other mechanisms.

  • Profiles and stereotypes: A UML profile is a package of stereotypes, tagged values, and constraints tailored for a domain. Profiles group these extensions; profiles themselves are not 'stereotyped' as a mechanism for backward compatibility.

Conclusion: The correct statement is that stereotypes are used to extend the UML language.

Explore the full course: Mppsc Assistant Professor