Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
ADDON::CBinaryAddonManager Class Reference

#include <BinaryAddonManager.h>

Public Member Functions

 CBinaryAddonManager ()=default
 
 CBinaryAddonManager (const CBinaryAddonManager &)=delete
 
 ~CBinaryAddonManager ()=default
 
BinaryAddonBasePtr GetAddonBase (const AddonInfoPtr &addonInfo, IAddonInstanceHandler *handler, AddonDllPtr &addon)
 Create or get available addon instance handle base.
 
void ReleaseAddonBase (const BinaryAddonBasePtr &addonBase, IAddonInstanceHandler *handler)
 Release a running addon instance handle base.
 
BinaryAddonBasePtr GetRunningAddonBase (const std::string &addonId) const
 Get running addon base class for a given addon id.
 
AddonPtr GetRunningAddon (const std::string &addonId) const
 Used from other addon manager to get active addon over a from him created CAddonDll.
 

Constructor & Destructor Documentation

◆ CBinaryAddonManager() [1/2]

ADDON::CBinaryAddonManager::CBinaryAddonManager ( )
default

◆ CBinaryAddonManager() [2/2]

ADDON::CBinaryAddonManager::CBinaryAddonManager ( const CBinaryAddonManager & )
delete

◆ ~CBinaryAddonManager()

ADDON::CBinaryAddonManager::~CBinaryAddonManager ( )
default

Member Function Documentation

◆ GetAddonBase()

BinaryAddonBasePtr CBinaryAddonManager::GetAddonBase ( const AddonInfoPtr & addonInfo,
IAddonInstanceHandler * handler,
AddonDllPtr & addon )

Create or get available addon instance handle base.

On first call the binary addon base class becomes created, on every next call of addon id, this becomes given again and a counter about in CBinaryAddonBase increased.

Parameters
[in]addonBaserelated addon base to release
[in]handlerrelated instance handle class
Warning
This and ReleaseAddonBase are only be called from IAddonInstanceHandler, use nowhere else allowed!

◆ GetRunningAddon()

AddonPtr CBinaryAddonManager::GetRunningAddon ( const std::string & addonId) const

Used from other addon manager to get active addon over a from him created CAddonDll.

Parameters
[in]addonIdrelated addon id string
Returns
if present the pointer to active one or nullptr if not present

◆ GetRunningAddonBase()

BinaryAddonBasePtr CBinaryAddonManager::GetRunningAddonBase ( const std::string & addonId) const

Get running addon base class for a given addon id.

Parameters
[in]addonIdthe addon id
Returns
running addon base class if found, nullptr otherwise.

◆ ReleaseAddonBase()

void CBinaryAddonManager::ReleaseAddonBase ( const BinaryAddonBasePtr & addonBase,
IAddonInstanceHandler * handler )

Release a running addon instance handle base.

On last release call the here on map stored entry becomes removed and the dll unloaded.

Parameters
[in]addonBaserelated addon base to release
[in]handlerrelated instance handle class

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