Skip to main content

Module contracts

Module contracts 

Source
Expand description

Flow contracts and plugin records carried by registration declarations. 注册声明携带的数据流合同与插件记录。

These are pure protocol nouns. They live in the plugin module because that is what they describe; declaration re-exports them so a declaration can keep naming them without a second copy in the tree. 这些是纯协议名词。它们住在 plugin 模块,因为描述的正是插件;declaration 再导出它们,让声明继续以原名引用,而不在树里出现第二份副本。

Structs§

ContractId
A logical replacement slot. Concrete implementations keep their own node identity; the slot is the stable name that a graft targets. 逻辑替换插槽。具体实现保留各自 node identity;嫁接针对的是稳定插槽名。
FlowContract
The mechanically comparable part of a data-flow contract. 数据流合同中可以机械比较的部分。
FrameworkId
A stable host identity. Package names are not enough when several frameworks share one process. 稳定的宿主身份。同一进程存在多个框架时,crate 名称并不足以区分目标。
OwnedFlowContract
Owned flow contract used by file-backed snapshots. 文件快照使用的拥有型数据流合同。
PluginManifest
Plugin manifest metadata. 插件 manifest 元数据。

Enums§

FlowSemantic
Normalized semantic labels used by tooling when string contracts are too coarse to explain a mismatch (for example local vs absolute coordinates). 调试工具使用的规范化语义标签,避免仅凭字符串无法解释坐标域差异。
PluginMode
Whether a plugin adds a new capability or replaces an existing slot. 插件是增加能力还是替换已有插槽。
PluginSource
Where the plugin came from. Trust policy is deliberately separate from registration structure and flow compatibility. 插件来源。信任策略与注册结构、数据流兼容性刻意分离。

Traits§

FlowContractProvider
A handle can expose its data-flow contract once; registration faces then read it without repeating input/output strings. handle 只需声明一次数据流合同;注册面直接读取,不重复填写输入输出字符串。