泳道分組并且著色
分組用 box和endbox ,顏色用#xxx,標注用"xxx"
box "瀏覽器" #LightGreen
participant "瀏覽器1" as Browser
participant "瀏覽器2" as Browser2
endboxparticipant "服務端" as Server #orange
未修改前:
修改后:
效果:可見圖中瀏覽器1和瀏覽器2放到了一起,并且叫瀏覽器的title
@startumlautonumberactor "用戶" as Userbox "瀏覽器" #LightGreen
participant "瀏覽器1" as Browser
participant "瀏覽器2" as Browser2
endboxparticipant "服務端" as Server #orangeactivate UserUser -> Browser: 輸入 URL
activate BrowserBrowser -> Server: 請求服務器
activate ServerServer -> Server: 模板渲染
note right of Server: 這是一個注釋Server -> Browser: 返回 HTML
deactivate ServerBrowser --> User@enduml