Interface IAlgorithmPluginManager
- Namespace
- DotCompute.Runtime.Services.Interfaces
- Assembly
- DotCompute.Runtime.dll
Algorithm plugin manager interface
public interface IAlgorithmPluginManager
Methods
GetPluginAsync<T>(string)
Gets a plugin by its ID
Task<T?> GetPluginAsync<T>(string pluginId) where T : class
Parameters
pluginIdstringThe plugin ID
Returns
- Task<T>
The plugin instance or null if not found
Type Parameters
TThe plugin interface type
GetPluginInfo()
Gets plugin information
IEnumerable<PluginInfo> GetPluginInfo()
Returns
- IEnumerable<PluginInfo>
Information about all loaded plugins
GetPluginsAsync<T>()
Gets all plugins of a specific type
Task<IEnumerable<T>> GetPluginsAsync<T>() where T : class
Returns
- Task<IEnumerable<T>>
All plugins of the specified type
Type Parameters
TThe plugin interface type
LoadPluginsAsync()
Loads all algorithm plugins from configured directories
Task LoadPluginsAsync()
Returns
- Task
A task representing the load operation
RegisterPluginAsync<T>(string, T)
Registers a plugin instance
Task RegisterPluginAsync<T>(string pluginId, T plugin) where T : class
Parameters
pluginIdstringThe plugin ID
pluginTThe plugin instance
Returns
- Task
A task representing the registration operation
Type Parameters
TThe plugin interface type
ReloadPluginsAsync()
Reloads all plugins (if hot reload is enabled)
Task ReloadPluginsAsync()
Returns
- Task
A task representing the reload operation
UnloadPluginAsync(string)
Unloads a plugin
Task UnloadPluginAsync(string pluginId)
Parameters
pluginIdstringThe plugin ID
Returns
- Task
A task representing the unload operation