From 30fd5fcf14f7a755ea17836511cfc15e58dc290e Mon Sep 17 00:00:00 2001 From: Jeremy Wu Date: Sun, 6 Oct 2019 11:50:25 +1000 Subject: [PATCH] Add interface that will be used by plugins --- Wox.Plugin/Interfaces/IReloadable.cs | 18 ++++++++++++++++++ Wox.Plugin/Wox.Plugin.csproj | 1 + 2 files changed, 19 insertions(+) create mode 100644 Wox.Plugin/Interfaces/IReloadable.cs diff --git a/Wox.Plugin/Interfaces/IReloadable.cs b/Wox.Plugin/Interfaces/IReloadable.cs new file mode 100644 index 0000000000..86f75ee3e9 --- /dev/null +++ b/Wox.Plugin/Interfaces/IReloadable.cs @@ -0,0 +1,18 @@ +namespace Wox.Plugin +{ + /// + /// This interface is to indicate and allow plugins to reload their + /// in memory data cache or other mediums when user makes a new change + /// that is not immediately captured. For example, for BrowserBookmark and Program + /// plugin does not automatically detect when a user added a new bookmark or program, + /// so this interface's function is exposed to allow user manually do the reloading after + /// those new additions. + /// + /// The command that allows user to manual reload is exposed via Plugin.Sys, and + /// it will call the plugins that have implemented this interface. + /// + public interface IReloadable + { + void ReloadData(); + } +} diff --git a/Wox.Plugin/Wox.Plugin.csproj b/Wox.Plugin/Wox.Plugin.csproj index 8b1e9f0ca7..843cc7d8bf 100644 --- a/Wox.Plugin/Wox.Plugin.csproj +++ b/Wox.Plugin/Wox.Plugin.csproj @@ -66,6 +66,7 @@ +