Sequence Diagram Macro

Last modified by Admin on 2022/05/23 00:15

chart_organisationDraw UML Sequence Diagrams
TypeXAR
CategoryMacro
Developed by

Vincent Massol

Active Installs39
Rating
0 Votes
LicenseGNU Lesser General Public License 2.1

Installable with the Extension Manager

Description

Draw UML Sequence Diagrams using Web Sequence Diagram.

Usage

{{sequence style="default|earth|modern-blue|mscgen|omegapple|qsd|rose|roundgreen|napkin"}}
content here...
{{/sequence}}

For more detail see the Web Sequence Diagram web site.

Parameters definition

NameOptionalAllowed valuesDefault valueDescription
styleyesa string"default"The style of the sequence diagram. Valid values are "default", "earth", "modern-blue", "mscgen", "omegapple", "qsd", "rose", "roundgreen" and "napkin"

Examples

Simple with Default style

{{sequence}}
Alice->Bob: Authentication Request
Bob-->Alice: Authentication Response
{{/sequence}}

Generates:

simple.png

Grouping with Blue style

{{sequence style="modern-blue"}}
Alice->Bob: Authentication Request
alt successful case
  Bob->Alice: Authentication Accepted
else some kind of failure
  Bob->Alice: Authentication Failure
  opt
    loop 1000 times
      Alice->Bob: DNS Attack
    end
  end
else Another type of failure
  Bob->Alice: Please repeat
end
{{/sequence}}

Generates:

grouping.png

Activation and Destruction with Napkin style

{{sequence style="napkin"}}
User->A: DoWork
activate A
A->B: <<createRequest>>
activate B
B->C: DoWork
activate C
C-->B: WorkDone
destroy C
B-->A: RequestCreated
deactivate B
A->User: Done
{{/sequence}}

Generates:

activation.png

Notes with Round Green style

{{sequence style="roundgreen"}}
participant Alice
participant Bob

note left of Alice
  This is displayed
  left of Alice.
end note
note right of Alice: This is displayed right of Alice.
note over Alice: This is displayed over Alice.
note over Alice, Bob: This is displayed over Bob and Alice.
{{/sequence}}

Generates:

notes.png

Prerequisites & Installation Instructions

We recommend using the Extension Manager to install this extension (Make sure that the text "Installable with the Extension Manager" is displayed at the top right location on this page to know if this extension can be installed with the Extension Manager). Note that installing Extensions when being offline is currently not supported and you'd need to use some complex manual method.

You can also use the following manual method, which is useful if this extension cannot be installed with the Extension Manager or if you're using an old version of XWiki that doesn't have the Extension Manager:

  1. Log in the wiki with a user having Administration rights
  2. Go to the Administration page and select the Import category
  3. Follow the on-screen instructions to upload the downloaded XAR
  4. Click on the uploaded XAR and follow the instructions
  5. You'll also need to install all dependent Extensions that are not already installed in your wiki

Release Notes

v1.0.3

v1.0.2

Just updated the extension's description. No other change from 1.0.1.

v1.0.1

v1.0

First version

Dependencies

Dependencies for this extension (org.xwiki.contrib:macro-sequence 1.0.3):

Tags:
    

Get Connected