Opening a predefined template

Document Publisher comes with a vast catalog of predefined templates. As a Template Editor user, it you can easily extend these templates, either to add the content of your choice, or to modify the way in which some parts of the model are generated.

The XML definition of all predefined templates can be found in the Template Editor’s installation directory.

ImportXML.png

Basic extension

Let’s take an example of a predefined template extension, starting from the "Use case catalog" presented earlier.

Let’s assume we want to replace the table of actors with a list, in order to distinguish it from the use case table generated in the same part of the document.

For this, carry out the steps illustrated in the following screenshot.

ExtendedUseCases.png
  1. Load the default template’s XML file ("UseCase.xml") from the resources in the Template Editor.

  2. Go to the point you want to modify (in this example, the procedure where the actor table is generated).

  3. Create the new nodes:

  4. Create a list node, and set its type to "bullet". Name it "ListOfActors".

  5. Add the same navigation node as "FindAllActors" in the table (it is a smart finder producing all actors).

  6. Add the list item producing the name of the actor. Name it "NameOfActor".

  7. Just delete the former "ListOfActors", this will delete all its children.

  8. Package the extended template.

Now, let’s take a look at the result of generating this template on the same example as in the previous chapter.

basic_extension2.png