Expand description
§Vine::Host
VineHost is the embedder-facing seam between Vine and its consumer
runtime. Mountain (Tauri runtime), Air (background daemon), and any
Rust-side Cocoon client implement this trait to expose the minimum
surface Vine’s notification handlers need: application-state access,
renderer event emission, and an IPCProvider handle for cross-channel
re-entrancy. Handlers operate on &dyn VineHost so a single handler
tree can be hosted against any embedder runtime.
§Design notes
ApplicationStatereturns&dyn ApplicationStateAccess. Vine treats application state as opaque; embedders decide what their state exposes via embedder-local sub-traits and downcasting.EmitToRendereris the single entry point for “send a value to the workbench / Sky window.” Mountain wires it totauri::WebviewWindow::emit; Air leaves it as a no-op (no renderer).IPCProviderreturnsArc<dyn IPCProvider>for handlers that need to re-enter the IPC bus.
§Stability
Adding methods to VineHost is a compatible change so long as every
impl is updated in the same revision. Removing a method requires
sweeping every consumer.
Traits§
- Application
State Access - Opaque application-state handle exposed to Vine handlers.
- IPCProvider
- Cross-channel IPC provider abstraction.
- Renderer
Emitter - Cheap-to-clone renderer event sink.
- Vine
Host - The embedder-facing seam between Vine and its host runtime.