IDE support
-
Phpstorm
Installation in Plugins
PlantUML integration
plug-in- ##Go to
http://www.graphviz.org/
website to download
graphviz.exeand install (this The software can support more UML syntax)
- Add the
dot.exe
path in the graphviz installation directory to the PlantUML settings
- Document address:
http://plantuml.com/
- It is recommended to use
Activity Diagram-Activity-bate
Syntax: Activity Diagram Activity-Beta(https://plantuml.com/zh/activity-diagram-beta)
- Activity diagram (new syntax)
The new syntax will replace the old syntax. However, for compatibility reasons, the old syntax can still be used to ensure forward compatibility.
But we encourage users to use the new syntax format.
@startuml
,
@endumlStart and end tags , representing the UML parsing part
start
,
endrepresents the start and end of the diagram. The beginning and end of the illustration.
:Hello world;
The activity label starts with a colon and ends with a semicolon. Activities are installed by default in the order in which they are defined.
if
,
then,
else, and
elseifset up branch tests. Label text is placed in brackets.
repeat
,
repeatwhileRepeat the loop.
while
and
endwhileperform a while loop. You can also add a label after the keyword
endwhile. Another way is to use the keyword
is.
fork
,
fork againand
end forkrepresent parallel processing.
note
,
end note,
floating note left, etc. represent comments, for example:
floating note left: This is a note :foo2; note right This note is on several //lines// and can contain <b>HTML</b> ==== * Calling the method ""foo()"" is prohibited end note
#HotPin:activity;
、
#AAAAAA:ending of the process;represents the color
- Using the
->
tag, you can add text to the arrow or change the arrow color.
dotted,
dashed,
boldor
hidden arrowsand color tags, such as
-[#blue]-> - By defining partitions, you can group multiple activities together. By defining partitions, you can group multiple activities together. For example:
partition Initialization { :read config file; :init internal variable; }
- Use the pipe character | to define swim lanes. You can also change the color of the swim lanes.
|Swimlane1| start :foo1; |#AntiqueWhite|Swimlane2| :foo2; :foo3; |Swimlane1| :foo4; |Swimlane2| :foo5; stop
- Keywords
detach
Remove the arrow.
- You can set different shapes for activities by modifying the semicolon separator (;) at the end of the activity label.
|,,/,],}
:next(o)| :Receiving; split :nak(i) split again :ack(i) split again :err(i) split again :foo/ split again :i > 5} stop end split :finish;An example