- 将ASCII文字图替换为专业的Excalidraw图表 - 新增4个可视化图表:三大核心组件架构、Selector多路复用模型、Buffer核心属性、零拷贝原理对比 - 图表使用配色方案区分不同组件(蓝色-Channel, 绿色-Buffer, 橙色-Selector) - 在Obsidian中可通过![[...]]语法直接嵌入查看
513 lines
12 KiB
Markdown
513 lines
12 KiB
Markdown
---
|
|
excalidraw-plugin: parsed
|
|
tags: [excalidraw]
|
|
---
|
|
==⚠ Switch to EXCALIDRAW VIEW in the MORE OPTIONS menu of this document. ⚠== You can decompress Drawing data with the command palette: 'Decompress current Excalidraw file'. For more info check in plugin settings under 'Saving'
|
|
|
|
# Excalidraw Data
|
|
|
|
## Text Elements
|
|
%%
|
|
## Drawing
|
|
```json
|
|
{
|
|
"type": "excalidraw",
|
|
"version": 2,
|
|
"source": "https://github.com/zsviczian/obsidian-excalidraw-plugin",
|
|
"elements": [
|
|
{
|
|
"id": "title",
|
|
"type": "text",
|
|
"x": 400,
|
|
"y": 30,
|
|
"width": 400,
|
|
"height": 35,
|
|
"angle": 0,
|
|
"strokeColor": "#1e40af",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": null,
|
|
"seed": 1,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"text": "Selector 多路复用模型",
|
|
"fontSize": 28,
|
|
"fontFamily": 5,
|
|
"textAlign": "center",
|
|
"verticalAlign": "middle",
|
|
"containerId": null,
|
|
"originalText": "Selector 多路复用模型",
|
|
"autoResize": true,
|
|
"lineHeight": 1.25
|
|
},
|
|
{
|
|
"id": "selector-container",
|
|
"type": "rectangle",
|
|
"x": 200,
|
|
"y": 120,
|
|
"width": 800,
|
|
"height": 250,
|
|
"angle": 0,
|
|
"strokeColor": "#f59e0b",
|
|
"backgroundColor": "#fff3bf",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 3,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 30,
|
|
"groupIds": [],
|
|
"roundness": {"type": 3},
|
|
"seed": 2,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false
|
|
},
|
|
{
|
|
"id": "selector-box",
|
|
"type": "rectangle",
|
|
"x": 480,
|
|
"y": 145,
|
|
"width": 240,
|
|
"height": 80,
|
|
"angle": 0,
|
|
"strokeColor": "#e67700",
|
|
"backgroundColor": "#ffd8a8",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": {"type": 3},
|
|
"seed": 3,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false
|
|
},
|
|
{
|
|
"id": "selector-text",
|
|
"type": "text",
|
|
"x": 535,
|
|
"y": 160,
|
|
"width": 130,
|
|
"height": 50,
|
|
"angle": 0,
|
|
"strokeColor": "#e67700",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": null,
|
|
"seed": 4,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"text": "Selector\nselect「」等待",
|
|
"fontSize": 20,
|
|
"fontFamily": 5,
|
|
"textAlign": "center",
|
|
"verticalAlign": "middle",
|
|
"containerId": null,
|
|
"originalText": "Selector\nselect「」等待",
|
|
"autoResize": true,
|
|
"lineHeight": 1.25
|
|
},
|
|
{
|
|
"id": "channel1-box",
|
|
"type": "rectangle",
|
|
"x": 250,
|
|
"y": 270,
|
|
"width": 120,
|
|
"height": 60,
|
|
"angle": 0,
|
|
"strokeColor": "#1971c2",
|
|
"backgroundColor": "#a5d8ff",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": {"type": 3},
|
|
"seed": 5,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false
|
|
},
|
|
{
|
|
"id": "channel1-text",
|
|
"type": "text",
|
|
"x": 275,
|
|
"y": 285,
|
|
"width": 70,
|
|
"height": 30,
|
|
"angle": 0,
|
|
"strokeColor": "#1864ab",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": null,
|
|
"seed": 6,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"text": "Channel1\n就绪",
|
|
"fontSize": 16,
|
|
"fontFamily": 5,
|
|
"textAlign": "center",
|
|
"verticalAlign": "middle",
|
|
"containerId": null,
|
|
"originalText": "Channel1\n就绪",
|
|
"autoResize": true,
|
|
"lineHeight": 1.25
|
|
},
|
|
{
|
|
"id": "channel2-box",
|
|
"type": "rectangle",
|
|
"x": 440,
|
|
"y": 270,
|
|
"width": 120,
|
|
"height": 60,
|
|
"angle": 0,
|
|
"strokeColor": "#1971c2",
|
|
"backgroundColor": "#a5d8ff",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": {"type": 3},
|
|
"seed": 7,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false
|
|
},
|
|
{
|
|
"id": "channel2-text",
|
|
"type": "text",
|
|
"x": 465,
|
|
"y": 285,
|
|
"width": 70,
|
|
"height": 30,
|
|
"angle": 0,
|
|
"strokeColor": "#1864ab",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": null,
|
|
"seed": 8,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"text": "Channel2\n就绪",
|
|
"fontSize": 16,
|
|
"fontFamily": 5,
|
|
"textAlign": "center",
|
|
"verticalAlign": "middle",
|
|
"containerId": null,
|
|
"originalText": "Channel2\n就绪",
|
|
"autoResize": true,
|
|
"lineHeight": 1.25
|
|
},
|
|
{
|
|
"id": "channel3-box",
|
|
"type": "rectangle",
|
|
"x": 630,
|
|
"y": 270,
|
|
"width": 120,
|
|
"height": 60,
|
|
"angle": 0,
|
|
"strokeColor": "#1971c2",
|
|
"backgroundColor": "#a5d8ff",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": {"type": 3},
|
|
"seed": 9,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false
|
|
},
|
|
{
|
|
"id": "channel3-text",
|
|
"type": "text",
|
|
"x": 655,
|
|
"y": 285,
|
|
"width": 70,
|
|
"height": 30,
|
|
"angle": 0,
|
|
"strokeColor": "#1864ab",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": null,
|
|
"seed": 10,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"text": "Channel3\n就绪",
|
|
"fontSize": 16,
|
|
"fontFamily": 5,
|
|
"textAlign": "center",
|
|
"verticalAlign": "middle",
|
|
"containerId": null,
|
|
"originalText": "Channel3\n就绪",
|
|
"autoResize": true,
|
|
"lineHeight": 1.25
|
|
},
|
|
{
|
|
"id": "channel-dots",
|
|
"type": "text",
|
|
"x": 800,
|
|
"y": 285,
|
|
"width": 50,
|
|
"height": 30,
|
|
"angle": 0,
|
|
"strokeColor": "#374151",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": null,
|
|
"seed": 11,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"text": "...",
|
|
"fontSize": 24,
|
|
"fontFamily": 5,
|
|
"textAlign": "center",
|
|
"verticalAlign": "middle",
|
|
"containerId": null,
|
|
"originalText": "...",
|
|
"autoResize": true,
|
|
"lineHeight": 1.25
|
|
},
|
|
{
|
|
"id": "eventloop-box",
|
|
"type": "rectangle",
|
|
"x": 400,
|
|
"y": 420,
|
|
"width": 400,
|
|
"height": 120,
|
|
"angle": 0,
|
|
"strokeColor": "#7c3aed",
|
|
"backgroundColor": "#d0bfff",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": {"type": 3},
|
|
"seed": 12,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false
|
|
},
|
|
{
|
|
"id": "eventloop-title",
|
|
"type": "text",
|
|
"x": 520,
|
|
"y": 435,
|
|
"width": 160,
|
|
"height": 30,
|
|
"angle": 0,
|
|
"strokeColor": "#5f3dc4",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": null,
|
|
"seed": 13,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"text": "Event Loop",
|
|
"fontSize": 24,
|
|
"fontFamily": 5,
|
|
"textAlign": "center",
|
|
"verticalAlign": "middle",
|
|
"containerId": null,
|
|
"originalText": "Event Loop",
|
|
"autoResize": true,
|
|
"lineHeight": 1.25
|
|
},
|
|
{
|
|
"id": "eventloop-desc",
|
|
"type": "text",
|
|
"x": 420,
|
|
"y": 480,
|
|
"width": 360,
|
|
"height": 45,
|
|
"angle": 0,
|
|
"strokeColor": "#374151",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": null,
|
|
"seed": 14,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"text": "• select「」 - 等待就绪事件\n• process「」 - 处理事件\n• repeat - 循环执行",
|
|
"fontSize": 16,
|
|
"fontFamily": 5,
|
|
"textAlign": "left",
|
|
"verticalAlign": "middle",
|
|
"containerId": null,
|
|
"originalText": "• select「」 - 等待就绪事件\n• process「」 - 处理事件\n• repeat - 循环执行",
|
|
"autoResize": true,
|
|
"lineHeight": 1.25
|
|
},
|
|
{
|
|
"id": "arrow-thread",
|
|
"type": "arrow",
|
|
"x": 600,
|
|
"y": 370,
|
|
"width": 0,
|
|
"height": 40,
|
|
"angle": 0,
|
|
"strokeColor": "#7c3aed",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 3,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": {"type": 2},
|
|
"seed": 15,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"points": [[0, 0], [0, 40]],
|
|
"lastCommittedPoint": null,
|
|
"startBinding": null,
|
|
"endBinding": null,
|
|
"startArrowhead": null,
|
|
"endArrowhead": "arrow"
|
|
},
|
|
{
|
|
"id": "label-onethread",
|
|
"type": "text",
|
|
"x": 615,
|
|
"y": 380,
|
|
"width": 100,
|
|
"height": 20,
|
|
"angle": 0,
|
|
"strokeColor": "#7c3aed",
|
|
"backgroundColor": "transparent",
|
|
"fillStyle": "solid",
|
|
"strokeWidth": 2,
|
|
"strokeStyle": "solid",
|
|
"roughness": 1,
|
|
"opacity": 100,
|
|
"groupIds": [],
|
|
"roundness": null,
|
|
"seed": 16,
|
|
"version": 1,
|
|
"isDeleted": false,
|
|
"boundElements": null,
|
|
"updated": 1,
|
|
"link": null,
|
|
"locked": false,
|
|
"text": "单线程管理",
|
|
"fontSize": 16,
|
|
"fontFamily": 5,
|
|
"textAlign": "left",
|
|
"verticalAlign": "middle",
|
|
"containerId": null,
|
|
"originalText": "单线程管理",
|
|
"autoResize": true,
|
|
"lineHeight": 1.25
|
|
}
|
|
],
|
|
"appState": {
|
|
"gridSize": null,
|
|
"viewBackgroundColor": "#ffffff"
|
|
},
|
|
"files": {}
|
|
}
|
|
```
|
|
%% |