Class annotation

The UML annotations for a class or interface are stored at the end of their Java Doc. In general, we can find three kinds of tags:

@uml.stereotype

@uml.dependency

@uml.dependencyStereotype

We take an example of user-defined stereotype JDO, which contains an attribute “table” of type String to indicate the storage in relational database.

If we provide the “ COMPANY” value to attribute “ table”, this stereotype will be stored in the class tags:

/**
 * @uml.stereotype uml_id="JDO::JDOClass" table="COMPANY"
 */
public class Company
{
}