Inter-Addon Communication

Mods talking to an addon or more than one addon in Nitrocid

Inter-Addon Communication allows your mods to execute the publicly-available functions of a kernel addon. It allows your mods to talk to the kernel addons in a mechanism that doesn't interfere with the other end's operations.

How to call a publicly accessible addon function?

To execute custom addon functions in your mod, you must specify the full addon name, such as Extras - RSS Shell, and the function to execute in the ExecuteCustomAddonFunction() method:

public static object ExecuteCustomAddonFunction(KnownAddons addonName, string functionName)
public static object ExecuteCustomAddonFunction(KnownAddons addonName, string functionName, params object[] parameters)
public static object ExecuteCustomAddonFunction(string addonName, string functionName)
public static object ExecuteCustomAddonFunction(string addonName, string functionName, params object[] parameters)

How can I get/set a value from/to a property or a field?

To get a property value or a field value from an addon, you can call the following functions:

public static object GetCustomAddonPropertyValue(KnownAddons addonName, string propertyName)
public static object GetCustomAddonFieldValue(KnownAddons addonName, string fieldName)
public static object GetCustomAddonPropertyValue(string addonName, string propertyName)
public static object GetCustomAddonFieldValue(string addonName, string fieldName)

Similarly, to set a property value or a field value declared publicly by an addon, you can call the following functions:

public static void SetCustomAddonPropertyValue(KnownAddons addonName, string propertyName, object value)
public static void SetCustomAddonFieldValue(KnownAddons addonName, string fieldName, object value)
public static void SetCustomAddonPropertyValue(string addonName, string propertyName, object value)
public static void SetCustomAddonFieldValue(string addonName, string fieldName, object value)

Listing functions, properties, and fields

You can now list all the available functions, properties, and fields from a specific mod using one of the following functions:

InterAddonTools.cs
public static string[] ListAvailableFunctions(string addonName)
public static string[] ListAvailableProperties(string addonName)
public static string[] ListAvailableFields(string addonName)

Listing function and set property parameters

You can list all the function and set property parameters in depth by using the following functions:

public static ParameterInfo[] GetFunctionParameters(string addonName, string functionName)
public static ParameterInfo[] GetSetPropertyParameters(string addonName, string propertyName)

Supported addons

Items that are marked in green, yellow, and red resemble functions, properties, and fields respectively. The following addons support inter-addon communication:

  • Nitrocid.Extras.ArchiveShell

    • ListArchiveEntries

    • ExtractFileEntry

    • PackFile

    • ChangeWorkingArchiveDirectory

    • ChangeWorkingArchiveLocalDirectory

  • Nitrocid.Extras.Calendar

    • PrintCalendar

    • PrintCalendar2

    • PrintCalendar3

    • AddEvent

    • RemoveEvent

    • ListEvents

    • LoadEvents

    • LoadEvent

    • SaveEvents

    • SaveEvents2

    • SaveEvent

    • SaveEvent2

    • AddReminder

    • RemoveReminder

    • ListReminders

    • LoadReminders

    • LoadReminder

    • SaveReminders

    • SaveReminders2

    • SaveReminder

    • SaveReminder2

  • Nitrocid.Extras.Contacts

    • GetContacts

    • ImportContacts

    • InstallContacts

    • InstallContacts2

    • InstallContactFromMeCard

    • RemoveContact

    • RemoveContacts

    • GetContact

    • SearchNext

    • SearchNext2

    • SearchPrevious

    • SearchPrevious2

  • Nitrocid.Extras.Diagnostics

    • GetThreadBacktraces

  • Nitrocid.Extras.Docking

    • DockScreen

    • DockScreen2

    • DoesDockScreenExist

    • GetDockScreenNames

    • GetDockScreens

  • Nitrocid.Extras.Forecast

    • GetWeatherInfo

    • GetWeatherInfo2

    • PrintWeatherInfo

    • PrintWeatherInfo2

    • GetWeatherInfoOwm

    • GetWeatherInfoOwm2

    • GetWeatherInfoOwm3

    • GetWeatherInfoOwm4

    • PrintWeatherInfoOwm

    • PrintWeatherInfoOwm2

    • PreferredUnit

  • Nitrocid.Extras.FtpShell

    • FTPListRemote

    • FTPListRemote2

    • FTPDeleteRemote

    • FTPChangeRemoteDir

    • FTPMoveItem

    • FTPCopyItem

    • FTPChangePermissions

    • FTPGetHash

    • FTPGetHashes

    • FTPGetHashes2

    • FTPGetFile

    • FTPGetFile2

    • FTPGetFolder

    • FTPGetFolder2

    • FTPUploadFile

    • FTPUploadFile2

    • FTPUploadFolder

    • FTPUploadFolder2

    • FTPDownloadToString

    • PromptForPassword

    • TryToConnect

    • FileProgress

    • MultipleProgress

  • Nitrocid.Extras.HttpShell

    • HttpDelete

    • HttpGetString

    • HttpGet

    • HttpPutString

    • HttpPutFile

    • HttpPostString

    • HttpPostFile

    • HttpAddHeader

    • HttpRemoveHeader

    • HttpListHeaders

    • HttpGetCurrentUserAgent

    • HttpSetUserAgent

    • NeutralizeUri

  • Nitrocid.Extras.JsonShell

    • OpenJsonFile

    • CloseJsonFile

    • SaveFile

    • SaveFile2

    • WasJsonEdited

    • DetermineRootType

    • DetermineType

    • GetToken

    • GetTokenSafe

    • GetTokenSafe2

    • Add

    • Set

    • Remove

    • SerializeToString

  • Nitrocid.Extras.MailShell

    • CreateMailDirectory

    • DeleteMailDirectory

    • RenameMailDirectory

    • OpenFolder

    • MailListDirectories

    • MailListMessages

    • MailListMessages2

    • MailRemoveMessage

    • MailRemoveAllBySender

    • MailMoveAllBySender

    • DecryptMessage

    • MailSendMessage

    • MailSendMessage2

    • MailSendEncryptedMessage

    • PopulateMessages

    • ShowPreview

  • Nitrocid.Extras.RssShell

    • GetFirstArticle

    • SearchArticles

    • AddRSSFeedToBookmark

    • AddRSSFeedToBookmark2

    • RemoveRSSFeedFromBookmark

    • RemoveRSSFeedFromBookmark2

    • GetBookmarks

    • GetBookmark

  • Nitrocid.Extras.SftpShell

    • SFTPListRemote

    • SFTPListRemote2

    • SFTPDeleteRemote

    • SFTPChangeRemoteDir

    • SFTPChangeLocalDir

    • SFTPGetCanonicalPath

    • SFTPGetFile

    • SFTPUploadFile

    • SFTPDownloadToString

    • PromptConnectionInfo

    • SFTPTryToConnect

  • Nitrocid.Extras.SqlShell

    • IsSql

    • SqlEdit_OpenSqlFile

    • SqlEdit_CheckSqlFile

    • SqlEdit_SqlCommand

  • Nitrocid.Extras.Ssh

    • PromptConnectionInfo

    • GetConnectionInfo

    • InitializeSSH

    • OpenShell

    • OpenShell2

    • OpenCommand

    • OpenCommand2

  • Nitrocid.Extras.ToDoList

    • AddTask

    • RemoveTask

    • GetTask

    • GetTaskIndex

    • TaskExists

    • SetDone

    • SetUndone

    • GetTaskNames

    • SaveTasks

    • LoadTasks