What is true about UML stereotypes ?
2014
What is true about UML stereotypes ?
- A.
Stereotype is used for extending the UML language.
- B.
Stereotyped class must be abstract
- C.
The stereotype indicates that the UML element cannot be changed
- 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.