Text generation

Writing scripts inside a Text editor has a lot of inconveniences but the great advantage is to benefit from all text edition functionalities, mainly styles and formatting, from the Text editor.

Applying styles to the generation output

The style applied to the script inside template document is kept in the generation output (color, font, size, alignment,…).

Template content

Generation output

<context model=‘…’/>
<gendoc>
 [for (p:Package|self.ownedElement->filter(Package))]
 [p.name/]
 [/for]
</gendoc>

Actors
Use case view
Logical view
Deployment view

Using bullets and numbering

With the same example as in the previous paragraph, other style information such as bullets or numbering can be used for generation.

Template content

Generation output

<context model=‘…’/>
<gendoc>
 [for (p:Package|self.ownedElement->filter(Package))]

  • [p.name/]

 [/for]
</gendoc>

  • Actors
  • Use case view
  • Logical view
  • Deployment view

 

Template content

Generation output

<context model=‘…’/>
<gendoc>
 [for (p:Package|self.ownedElement->filter(Package))]

  1. [p.name/]

  [for (p2:Package|p.ownedElement->filter(Package))]

  1. [p2.name/]

  [/for]
 [/for]
</gendoc>

  1. Actors
  2. Use case view
    1. Data import
    2. Data export
  3. Logical view
  4. Deployment view
    1. Server side
    2. ClientSide

All other styles from document templates are kept during generation.