Table of Contents

Interface IPlugin

Namespace
Hi3Helper.Plugin.Core
Assembly
Hi3Helper.Plugin.Core.dll

The plugin interface for accessing plugin metadata and preset configuration.

[GeneratedComInterface]
[Guid("436f6c6c-6170-7365-727f-000000000010")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[IUnknownDerived<InterfaceInformation, InterfaceImplementation>]
public interface IPlugin : IFree

Remarks

This IPlugin interface provides information about the plugin and the IPluginPresetConfig interface to access the preset configuration.

Methods

CancelAsync(in Guid)

Cancels an asynchronous operation associated with the specified cancellation token.

void CancelAsync(in Guid cancelToken)

Parameters

cancelToken Guid

The token identifying the operation to cancel.

Free()

void Free()

GetNotificationPosterUrl(out string?)

Gets the notification poster URL of the plugin.

void GetNotificationPosterUrl(out string? result)

Parameters

result string

The notification poster URL of the plugin.

GetPluginAppIconUrl(out string?)

Gets the app icon URL of the plugin.

void GetPluginAppIconUrl(out string? result)

Parameters

result string

The icon URL of the plugin.

GetPluginAuthor(out string?)

Gets information about the author of the plugin.

void GetPluginAuthor(out string? result)

Parameters

result string

The author information.

GetPluginCreationDate(out DateTime*)

Gets the creation date of the plugin.

void GetPluginCreationDate(out DateTime* result)

Parameters

result DateTime*

A pointer to a DateTime instance representing the creation date (Equivalent to DateTime** result).

GetPluginDescription(out string?)

Gets the description of the plugin.

void GetPluginDescription(out string? result)

Parameters

result string

The description of the plugin or game.

GetPluginName(out string?)

Gets the name of the plugin or the game it represents.

void GetPluginName(out string? result)

Parameters

result string

The name of the plugin or game.

GetPluginSelfUpdater(out IPluginSelfUpdate?)

Gets the plugin self-updater instance.

void GetPluginSelfUpdater(out IPluginSelfUpdate? selfUpdate)

Parameters

selfUpdate IPluginSelfUpdate

An instance to IPluginSelfUpdate.

GetPresetConfig(int, out IPluginPresetConfig)

Gets a specific IPluginPresetConfig instance by index.

void GetPresetConfig(int index, out IPluginPresetConfig presetConfig)

Parameters

index int

The index of the preset configuration.

presetConfig IPluginPresetConfig

The IPluginPresetConfig instance at the specified index.

GetPresetConfigCount(out int)

Gets the number of available IPluginPresetConfig instances.

void GetPresetConfigCount(out int count)

Parameters

count int

The count of how much Plugin Preset Configs are available.

SetPluginLocaleId(string?)

Set the locale ID for the plugin.

void SetPluginLocaleId(string? localeId)

Parameters

localeId string

The locale ID to be set (for example: en-US)

SetPluginProxySettings(string?, string?, string?, out bool)

Sets the proxy settings used by the plugin. To reset the configuration, set all arguments as null

void SetPluginProxySettings(string? hostUri, string? username, string? password, out bool isSuccess)

Parameters

hostUri string

The host URI of the proxy server.
Only few Proxy protocol supported by the plugin, including: http://, https://, socks4:// and socks5://

username string

The username for proxy authentication. Leave it as null if none is needed.

password string

The password for proxy authentication. Leave it as null if none is needed.

isSuccess bool

Returns true if the settings are valid. Otherwise, returns false.