This page lists some features that have not been officially integrated into PlantUML. Those features are working, but subject to changes. So you should NOT use them in real diagrams.
They are here so that users can make suggestions on the Q&A board or by mail before official release.
@startuml
Bob -> Alice : hello
activate Alice
Alice -> Alice : some action
return bye
@enduml
Immediately after specifying the target participant, the following syntax can be used:
Symbol | Usage |
++ | Activate the target (optionally a #color may follow this) |
-- | Deactivate the source |
** | Create an instance of the target |
!! | Destroy an instance of the target |
@startuml
alice -> bob ++ : hello
bob -> bob ++ : self call
bob -> bib ++ #005500 : hello
bob -> geoge ** : create
return done
return rc
bob -> geoge !! : delete
return success
@enduml
@startuml
autoactivate on
Bob -> Alice : hello
Bob <-- Alice : ok2
@enduml
This works with the return
keywords:
@startuml
autoactivate on
alice -> bob : hello
bob -> bob : self call
bill -> bob #005500 : hello from thread 2
bob -> geoge ** : create
return done in thread 2
return rc
bob -> geoge !! : delete
return success
@enduml
@startuml
State S1
State S2
S1 -[#DD00AA]-> S2
S1 -left[#yellow]-> S3
S1 -up[#red,dashed]-> S4
S1 -right[dotted,#blue]-> S5
X1 -[dashed]-> X2
Z1 -[dotted]-> Z2
Y1 -[#blue,bold]-> Y2
@enduml
@startuml
Dummy -> Alice : foo1
ref over Alice, Dummy : [[http://www.google.com]] Foo2
Alice -> Bob : hello
ref over Alice, Bob
[[http://www.google.com]]
this is a
reference over
Alice and Bob
end
@enduml
You can use the url of XXX is [[xxx]]
syntax.
@startuml
Bob -> Alice : ok
url of Bob is [[http://www.google.com]]
@enduml
@startuml
skinparam topurl http://www.google.com
Dog --|> Mammal
url of Mammal is [[/search]]
url of Dog is [[http://www.yahoo.com{This is Dog}]]
Dog o-- Cat
Cat --|> Mammal
@enduml
@startuml
actor Mamal
usecase Dog
url of Mamal is [[http://www.google.com]]
url of Dog is [[http://www.yahoo.com{This is Dog}]]
@enduml
It is also possible to specify a link at the beginning of a note (the link applies to the full note), or inside a note (for a portion of the note).
@startuml
:Foo:
note left of Foo
[[http://www.google.com]]
This is a note
end note
note right of Foo
Yet another link to [[http://www.google.com]] as demo.
You can also [[http://www.yahoo.fr specify a text]] for the link.
And even [[http://www.yahoo.fr{This is a tooltip} add a tooltip]] to the link.
end note
@enduml
For classes, you can specify link for fields or methods:
@startuml
Object <|-- Foo
class Foo {
[[http://www.google.com]]
+ methods1() [[http://www.yahoo.com/A1{Some explainations about this method}]]
+ methods2() [[http://www.yahoo.com/A2]]
}
class Foo2 {
+ methods1() [[http://www.yahoo.com/B1]]
+ methods2() [[http://www.yahoo.com/B2]]
}
class Object {
[[http://www.yahoo.com]]
}
@enduml
@startuml
Object ^-- AbstractList
class ArrayList extends Object {
int size
}
interface List extends Collection {
add()
}
interface Set extends Collection
class TreeSet implements SortedSet
@enduml
@startuml
class Station {
+name: string
}
class StationCrossing {
+cost: TimeInterval
}
<> diamond
StationCrossing . diamond
diamond - "from 0..*" Station
diamond - "to 0..*" Station
@enduml
@startuml
(*) -> "foo"
note on link: this is a note
@enduml
@startuml
class Foo1
class Foo2
Foo1 --> Foo2 : Some information
note on link
You can put note
On several lines
end note
Foo2 --> Foo3 : Another text
note right on link : here a note on 1 line
@startuml
caller -> server : conReq
hnote over caller : idle
caller <- server : conConf
hnote over caller : connected
note over server : connected
rnote over server
this is
on several
lines
endrnote
hnote over caller
this is
on several
lines
endhnote
@enduml
@startuml
class foo1
package pack1 <<st>> {
legend
This is the legend for the package1
on several lines
end legend
class foo2
}
package pack2 {
legend
This is the legend for the package2
end legend
class foo3
}
legend
This is the legend for the diagram
on several lines
end legend
@enduml