OpenAssetIO
An abstract API for generalising interactions between a host application and an asset management system
HybridPluginSystemManagerImplementationFactory Class Reference

The hybrid plugin system composes one or more child plugin systems, and abstracts away routing API calls based on priority and capability. More...

#include <HybridPluginSystemManagerImplementationFactory.hpp>

Inheritance diagram for HybridPluginSystemManagerImplementationFactory:

Public Types

using ManagerImplementationFactoryInterfaces = std::vector< hostApi::ManagerImplementationFactoryInterfacePtr >
 
using Ptr = HybridPluginSystemManagerImplementationFactoryPtr
 
using ConstPtr = HybridPluginSystemManagerImplementationFactoryConstPtr
 
- Public Types inherited from ManagerImplementationFactoryInterface
using Ptr = ManagerImplementationFactoryInterfacePtr
 
using ConstPtr = ManagerImplementationFactoryInterfaceConstPtr
 

Public Member Functions

Identifiers identifiers () override
 Get a list of all manager plugin identifiers known to all child factories. More...
 
managerApi::ManagerInterfacePtr instantiate (const Identifier &identifier) override
 Create an instance of the ManagerInterface with the specified identifier. More...
 
- Public Member Functions inherited from ManagerImplementationFactoryInterface
 ManagerImplementationFactoryInterface (log::LoggerInterfacePtr logger)
 Construct an instance of this class. More...
 
virtual ~ManagerImplementationFactoryInterface ()
 Defaulted polymorphic destructor. More...
 

Static Public Member Functions

static HybridPluginSystemManagerImplementationFactoryPtr make (ManagerImplementationFactoryInterfaces factories, log::LoggerInterfacePtr logger)
 Construct a new instance. More...
 

Additional Inherited Members

- Protected Member Functions inherited from ManagerImplementationFactoryInterface
const log::LoggerInterfacePtrlogger () const
 Get logger instance. More...
 

Detailed Description

The hybrid plugin system composes one or more child plugin systems, and abstracts away routing API calls based on priority and capability.

A list of factories are provided in priority order. When a plugin with a particular identifier is requested, all factories are queried and any that return positively for the identifier have their resulting ManagerInterface instances composed into a single ManagerInterface, such that API calls are dispatched to the appropriate child instance, based on priority and capability.

Manager plugins advertise their capabilities using ManagerInterface.hasCapability.

If multiple plugins support the same capability, then priority is given to the plugin corresponding to the earliest in the list of provided child factories.

Member Typedef Documentation

Member Function Documentation

Identifiers identifiers ( )
overridevirtual

Get a list of all manager plugin identifiers known to all child factories.

Returns
List of known manager plugin identifiers.

Implements ManagerImplementationFactoryInterface.

managerApi::ManagerInterfacePtr instantiate ( const Identifier identifier)
overridevirtual

Create an instance of the ManagerInterface with the specified identifier.

If multiple factories return a positive result for the identifier, composition is performed to create a single ManagerInterface that dispatches API calls to the appropriate child instance, based on advertised capability or priority order.

Note that, like any other plugin system, the returned ManagerInterface cannot be used until initialized.

Parameters
identifierIdentifier of the ManagerInterface to instantiate.
Returns
Newly created interface.
Exceptions
InputValidationExceptionif the requested identifier has not been registered as a manager plugin.

Implements ManagerImplementationFactoryInterface.

Construct a new instance.

Parameters
factoriesList of factories to compose.
loggerLogger for progress and warnings.
Returns
New instance.

The documentation for this class was generated from the following file:
  • /src/src/openassetio-core/include/openassetio/pluginSystem/HybridPluginSystemManagerImplementationFactory.hpp