@deepseek-ai/dsh-typert-protocol 0.1.5-rc.2 → 0.1.6-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.i18n.yaml +1 -1
- package/README.zh.md +3 -3
- package/package.json +1 -1
package/README.i18n.yaml
CHANGED
|
@@ -3,4 +3,4 @@
|
|
|
3
3
|
# after editing either side, bring the other along and re-record with:
|
|
4
4
|
# pnpm run verify-translation-pairing --write packages/typert/protocol/README.md
|
|
5
5
|
README.md: 43147c2c2f1746ff0c806c0842b5dba65457775a
|
|
6
|
-
README.zh.md:
|
|
6
|
+
README.zh.md: c88432ff3587cba1a3222a3a4d75cd8fe0e2d514
|
package/README.zh.md
CHANGED
|
@@ -46,7 +46,7 @@ export class GoalService extends TypertRemoteService {
|
|
|
46
46
|
|
|
47
47
|
### 把 Host 对象与 Context 关联到 wire identity
|
|
48
48
|
|
|
49
|
-
复杂的 Host 对象不能直接跨 wire 传输。业务包通过可合并扩展的 `TypertLookupMap` 与 `TypertContextMap` 声明关联。Host Context
|
|
49
|
+
复杂的 Host 对象不能直接跨 wire 传输。业务包通过可合并扩展的 `TypertLookupMap` 与 `TypertContextMap` 声明关联。Host Context 适配器拥有稳定 wire 声明,并把 wire identity 解析为活跃 Context。Client Context 适配器需要双向映射,因为作用域调用从 Client Context 发起,而转发的 Host 事件要在 Client 侧解析其显式 wire identity。Host 组合可以覆盖其同步或异步解析器。因策略原因拒绝解析的解析器会抛出带有自身错误码的 `RemoteError`,该码原样到达调用方。
|
|
50
50
|
|
|
51
51
|
### 报告与读取 Remote 失败
|
|
52
52
|
|
|
@@ -65,7 +65,7 @@ throw new RemoteError('goal/not-found', `goal "${id}" does not exist`, { goalId:
|
|
|
65
65
|
|
|
66
66
|
### 在 Client 侧接收转发的 Host 事件
|
|
67
67
|
|
|
68
|
-
Host
|
|
68
|
+
Host 装配以转发给消费方的 Cordis 事件扩展 `TypertRemoteEventSelection`,从而收窄 `ctx.remote.$on` 的键集。`TypertForwardableEvent` 接受无作用域且返回 `void` 的通知,以及最后一个 `next()` 回调返回事件结果类型的异步作用域 waterfall(瀑布式事件)。`TypertClientEventListener` 从同一条 `Events` 成员派生 Client listener,并保留 signal、可选和只读字段、数组、回调与结果类型。`TypertClientRemote` 只公开 `$mount()` 与 `$on()`;事件传输仍由 Gateway 私有持有。
|
|
69
69
|
|
|
70
70
|
-----
|
|
71
71
|
|
|
@@ -83,7 +83,7 @@ Host 装配以转发给消费端的 Cordis 事件扩展 `TypertRemoteEventSelect
|
|
|
83
83
|
|
|
84
84
|
### Remote 标记
|
|
85
85
|
|
|
86
|
-
`@Remote` 与 `@RemoteScope` 调度一个初始化器,把方法名、可选导出名与调用模式追加到原型描述符;`remoteMethods(service)` 校验其版本,并返回与已存描述符分离、按声明顺序排列的快照,供 Gateway
|
|
86
|
+
`@Remote` 与 `@RemoteScope` 调度一个初始化器,把方法名、可选导出名与调用模式追加到原型描述符;`remoteMethods(service)` 校验其版本,并返回与已存描述符分离、按声明顺序排列的快照,供 Gateway 的源码模式回退读取。标记要求名称为字符串的公开、非静态实例方法,同一方法上的冲突标记会被拒绝。
|
|
87
87
|
|
|
88
88
|
### 协议映射与描述符
|
|
89
89
|
|
package/package.json
CHANGED