feat(sdk,plugins): API publique d'accès fichiers/workspace + analyse structure (#124,#129)

This commit is contained in:
2026-08-02 13:34:54 +02:00
parent 033e9a86d5
commit dce61ae1aa
27 changed files with 5895 additions and 94 deletions

View File

@ -0,0 +1,27 @@
/**
* Tauri adapter for stable public plugin events (#127).
*/
import { invoke } from "@tauri-apps/api/core";
import type { PluginEventBatch, PluginEventSubscription } from "@/domain";
import type {
PluginEventGateway,
PluginEventPollInput,
PluginEventSubscribeInput,
PluginEventUnsubscribeInput,
} from "@/ports";
export class TauriPluginEventGateway implements PluginEventGateway {
subscribe(input: PluginEventSubscribeInput): Promise<PluginEventSubscription> {
return invoke<PluginEventSubscription>("plugin_events_subscribe", { input });
}
poll(input: PluginEventPollInput): Promise<PluginEventBatch> {
return invoke<PluginEventBatch>("plugin_events_poll", { input });
}
unsubscribe(input: PluginEventUnsubscribeInput): Promise<PluginEventSubscription> {
return invoke<PluginEventSubscription>("plugin_events_unsubscribe", { input });
}
}