1
0
mirror of https://github.com/Artemis-RGB/Artemis synced 2025-12-13 05:48:35 +00:00
SpoinkyNL 05eed5ba00 Made devices aware of the plugin that loaded them
Fixed Corsair LL Fans layout
Expanded render events
Added identify option to device settings, must move this to be reusable though
2019-11-03 11:38:28 +01:00

36 lines
1.0 KiB
C#

using System;
using System.Threading.Tasks;
using Artemis.Core.Plugins.Models;
namespace Artemis.Core.Plugins.Abstract
{
/// <inheritdoc />
/// <summary>
/// This is the base plugin type, use the other interfaces such as Module to create plugins
/// </summary>
public abstract class Plugin : IDisposable
{
internal Plugin(PluginInfo pluginInfo)
{
PluginInfo = pluginInfo ?? throw new ArgumentNullException(nameof(pluginInfo));
}
public PluginInfo PluginInfo { get; internal set; }
/// <summary>
/// Called when the plugin is activated
/// </summary>
public abstract void EnablePlugin();
/// <summary>
/// Called when the plugin is deactivated
/// </summary>
public abstract void DisablePlugin();
/// <inheritdoc />
/// <summary>
/// Called when the plugin is unloaded, clean up any unmanaged resources here
/// </summary>
public abstract void Dispose();
}
}