Altova UModel 2024 Enterprise Edition

Documenting Elements

Home Prev Top Next

You can add documentation comments to modeling elements as follows:

 

Click the element (either in the diagram or in the Model Tree window).

Enter text in the Documentation window.

 

Any documentation text will be saved together with the project.

 

When an element is selected, its documentation is visible at all times in the Documentation window, if available. You can also display documentation as a comment on the diagram, as follows:

 

Right-click the element on the diagram, and select Show | Annotating Comments from the context menu.

 

Documentation hyperlinks

To create a hyperlink inside the Documentation window, select some text inside the window, right-click it and then select Insert/Edit Hyperlinks from the context menu. The hyperlink target can be a Web site, a diagram, a file, or another element, see also Hyperlinking Elements.

um_hyperlinks5

Documentation window

 

Code generation and documentation comments

If you generate code from class diagrams, any comments applied to classes and their members (in class diagrams) can be exported to the generated code as well. To do this, select the check box Write Documentation as Java Docs (for Java) or Write Documentation as DocComments (for C#, VB.NET) before generating program code, see also Code Generation Options.

 

Likewise, if you reverse engineer program code into a model, the code comments can be imported into the model. To do this, select the check box JavaDocs as Documentation (for Java) or DocComments as Documentation (for C#, VB.NET) before reverse engineering program code, see also Code Import Options.

 

For information about how comments in program code (or XML schemas) map to UModel comments, refer to the mapping tables for each language:

 

C# Mappings

VB.NET Mappings

Java Mappings

XML Schema Mappings

© 2017-2023 Altova GmbH