Note types for Java

 

Overview

Objecteering notes are used to complete the UML model with texts expressed in Java syntax.  Usually, the internal processing of a UML method is entered in Java in a "JavaCode" type note associated to a method's implementation.

 

Note:      Certain notes can be added to certain model elements directly through the "Java" tab of the auxiliary window.  For more information, please see "The auxiliary window and Java Developer".

 

 

Type of notes on a class

 

The ... type of note

is used to ...

JavaHeader

insert a text before declaring the class

JavaMembers

insert a text in the class body

JavaBottom

insert a text after declaring the class

Javadoc

add a comment to be used by javadoc

JavaTop

insert a comment before the java file's package instruction

JavaImport

generate and bring back imports in JavaImport notes, if the "Use Java import notes to generate imports" tickbox is checked, or if the {JavaNoImport} tagged value is present on the class in question.  This can only be used in model-driven mode, and not in round-trip mode.

JavaAnnotation

specify the annotation added to the class.

 

 

 

Type of notes on an operation

 

The ... type of note

is used to ...

Javadoc

add a comment which will be used by javadoc.

JavaCode

provide Java code for implementing the operation.

JavaSuper

insert Java code before the pre-condition (especially for calling the builder of the parent class).

JavaReturned

insert Java code after the post-condition (especially for instructing the method return).

JavaAnnotation

specify the annotation added to the operation.

 

 

 

Type of notes on an attribute

 

The ... type of note

is used to ...

JavaInitValueComment

add a comment after the initialization of an attribute.

Javadoc

add a comment  to be used by javadoc.

JavaAnnotation

specify the annotation added to the attribute.

 

 

 

Type of notes on a navigable association

 

The ... type of note

is used to ...

Javadoc

add a comment  to be used by javadoc

JavaInitValueComment

add a comment after the initialization of a navigable association.

JavaInitValue

set initialization for the association

JavaAnnotation

specify the annotation added to the association.

 

 

 

Type of notes on a package

 

The ... type of note

is used to ...

specific-xml

specify the content of an XML file to add to an EJB-JAR file, for platform-specific configuration.

JavaAnnotation

specify the annotation added to the package.