plantuml用法总结

时序图

参考

plantuml 复制代码
@startuml
skin rose
actor User as user
participant "Component A" as A
participant "Component B" as B
 
user -> A: Request data
activate A
A -> B: Sync Message -> data
activate B
B --> A: Return data
deactivate B
A --> user: Display data
deactivate A
 
user ->> A: Request another data (async)
activate A
A ->> B: Async Message -> another data
activate B
' No return message for async call, so we can leave it as it is or add a note for clarity
note right of B: Processing async request
B -->> A: (hidden,return)
deactivate B
note left of A: Async operation in progress
@enduml
plantuml 复制代码
@startuml
skin rose
title 生命线
participant User

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

deactivate A
@enduml
相关推荐
geovindu10 小时前
rust: Composite Pattern
开发语言·后端·设计模式·rust·组合模式
YYYing.14 小时前
【设计模式系列 (七) 】桥接模式
c++·后端·设计模式·桥接模式
阿狗童鞋1 天前
设计模式实战指南
设计模式
电子科技圈2 天前
基于车载SerDes和OpenGMSL协议的SoC设计与验证:行业高频问题解析
设计模式·车载系统·软件构建·设计规范
ClinicTech2 天前
高速冷冻离心机的温控系统与安全保护逻辑解析
设计模式·架构·健康医疗·设计语言
GISMagic2 天前
3.《设计模式》:软件设计与解耦能力提炼
设计模式·ai coding
染指11102 天前
131.Agent-Agent设计模式-MAS多智能体系统(Multi-Agent-System)
人工智能·设计模式·langchain·agent·agents
ShyanZh2 天前
【Python3基础】13-Python 常用设计模式
开发语言·python·设计模式
YYYing.3 天前
【设计模式系列 (五) 】原型模式
开发语言·后端·设计模式·原型模式·c/c++
长按助力退休3 天前
设计模式实战,这 5 个最常用
设计模式