Hermod
A cross-platform, modular and fully GDPR-compliant email archival solution!
Loading...
Searching...
No Matches
Hermod.PluginFramework.Plugin Class Referenceabstract

An abstract class for plugins with all the main features already implemented. More...

Inheritance diagram for Hermod.PluginFramework.Plugin:
Hermod.PluginFramework.IPlugin Hermod.EmailImport.EmailImporter

Public Member Functions

 Plugin (string pluginName, Version pluginVersion, params ICommand[] commands)
 Specialised constructor; allows inheriting classes to set their values immediately.
 
abstract void OnLoad (IPluginDelegator pluginDelegator)
 Method that is called once the plugin has been loaded. This may be used for pre-init purposes.
Parameters
pluginDelegatorThe delegator allocated to this plugin.

 
abstract void OnStart ()
 Method that is called once Hermod has completed its startup procedures and is ready to run.
 
abstract void OnStop ()
 Method that is called when Hermod is shutting down.
 
abstract void OnConfigChanged (ConfigChangedEventArgs e)
 Method that is called when an application-wide configuration has been modified.
Parameters
eThe ConfigChangedEventArgs that are generated when a config was modified.

 
abstract void OnConfigLoaded ()
 Method that is called when the application-wide configurations have been loaded.
 
void OnLoad (IPluginDelegator pluginDelegator)
 Method that is called once the plugin has been loaded. This may be used for pre-init purposes.
 
void OnStart ()
 Method that is called once Hermod has completed its startup procedures and is ready to run.
 
void OnStop ()
 Method that is called when Hermod is shutting down.
 
void OnConfigChanged (ConfigChangedEventArgs e)
 Method that is called when an application-wide configuration has been modified.
 
void OnConfigLoaded ()
 Method that is called when the application-wide configurations have been loaded.
 

Properties

Version PluginVersion [get, protected set]
 Gets the version of the plugin.
 
string PluginName [get, protected set]
 Gets the name of the plugin.
 
List< ICommandPluginCommands [get, protected set]
 A list of all commands this plugin provides.
 
- Properties inherited from Hermod.PluginFramework.IPlugin
Version PluginVersion [get]
 Gets the version of the plugin.
 
string PluginName [get]
 Gets the name of the plugin.
 
List< ICommandPluginCommands [get]
 A list of all commands this plugin provides.
 

Detailed Description

An abstract class for plugins with all the main features already implemented.

Definition at line 13 of file Plugin.cs.

Constructor & Destructor Documentation

◆ Plugin()

Hermod.PluginFramework.Plugin.Plugin ( string  pluginName,
Version  pluginVersion,
params ICommand[]  commands 
)
inline

Specialised constructor; allows inheriting classes to set their values immediately.

Parameters
pluginNameThe name of the plugin.
pluginVersionThe plugin's version.
commandsA list of commands (if any).

Definition at line 21 of file Plugin.cs.

21 {
22 PluginVersion = pluginVersion;
23 PluginName = pluginName;
24 PluginCommands = commands.ToList();
25 }
string PluginName
Gets the name of the plugin.
Definition: Plugin.cs:31
List< ICommand > PluginCommands
A list of all commands this plugin provides.
Definition: Plugin.cs:34
Version PluginVersion
Gets the version of the plugin.
Definition: Plugin.cs:28

References Hermod.PluginFramework.Plugin.PluginCommands, Hermod.PluginFramework.Plugin.PluginName, and Hermod.PluginFramework.Plugin.PluginVersion.

Member Function Documentation

◆ OnConfigChanged()

abstract void Hermod.PluginFramework.Plugin.OnConfigChanged ( ConfigChangedEventArgs  e)
pure virtual

Method that is called when an application-wide configuration has been modified.

Parameters
eThe ConfigChangedEventArgs that are generated when a config was modified.

Implements Hermod.PluginFramework.IPlugin.

Implemented in Hermod.EmailImport.EmailImporter.

◆ OnConfigLoaded()

abstract void Hermod.PluginFramework.Plugin.OnConfigLoaded ( )
pure virtual

Method that is called when the application-wide configurations have been loaded.

Implements Hermod.PluginFramework.IPlugin.

Implemented in Hermod.EmailImport.EmailImporter.

◆ OnLoad()

abstract void Hermod.PluginFramework.Plugin.OnLoad ( IPluginDelegator  pluginDelegator)
pure virtual

Method that is called once the plugin has been loaded. This may be used for pre-init purposes.

Parameters
pluginDelegatorThe delegator allocated to this plugin.

Implements Hermod.PluginFramework.IPlugin.

Implemented in Hermod.EmailImport.EmailImporter.

◆ OnStart()

abstract void Hermod.PluginFramework.Plugin.OnStart ( )
pure virtual

Method that is called once Hermod has completed its startup procedures and is ready to run.

Implements Hermod.PluginFramework.IPlugin.

Implemented in Hermod.EmailImport.EmailImporter.

◆ OnStop()

abstract void Hermod.PluginFramework.Plugin.OnStop ( )
pure virtual

Method that is called when Hermod is shutting down.

Implements Hermod.PluginFramework.IPlugin.

Implemented in Hermod.EmailImport.EmailImporter.

Property Documentation

◆ PluginCommands

List<ICommand> Hermod.PluginFramework.Plugin.PluginCommands
getprotected set

A list of all commands this plugin provides.

Implements Hermod.PluginFramework.IPlugin.

Definition at line 34 of file Plugin.cs.

34{ get; protected set; }

Referenced by Hermod.EmailImport.EmailImporter.EmailImporter(), and Hermod.PluginFramework.Plugin.Plugin().

◆ PluginName

string Hermod.PluginFramework.Plugin.PluginName
getprotected set

Gets the name of the plugin.

Implements Hermod.PluginFramework.IPlugin.

Definition at line 31 of file Plugin.cs.

31{ get; protected set; }

Referenced by Hermod.PluginFramework.Plugin.Plugin().

◆ PluginVersion

Version Hermod.PluginFramework.Plugin.PluginVersion
getprotected set

Gets the version of the plugin.

Implements Hermod.PluginFramework.IPlugin.

Definition at line 28 of file Plugin.cs.

28{ get; protected set; }

Referenced by Hermod.PluginFramework.Plugin.Plugin().


The documentation for this class was generated from the following file: