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

A factory to manage CppPluginSystemManagerPlugin derived plugins. More...

#include <CppPluginSystemManagerImplementationFactory.hpp>

Inheritance diagram for CppPluginSystemManagerImplementationFactory:

Public Types

using Ptr = CppPluginSystemManagerImplementationFactoryPtr
 
using ConstPtr = CppPluginSystemManagerImplementationFactoryConstPtr
 
- 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 the factory. 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 CppPluginSystemManagerImplementationFactoryPtr make (log::LoggerInterfacePtr logger)
 Construct a new instance. More...
 
static Ptr make (openassetio::Str paths, log::LoggerInterfacePtr logger)
 Construct a new instance. More...
 

Static Public Attributes

static constexpr std::string_view kPluginEnvVar = "OPENASSETIO_PLUGIN_PATH"
 Environment variable to read the plugin search path from. More...
 

Additional Inherited Members

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

Detailed Description

A factory to manage CppPluginSystemManagerPlugin derived plugins.

This class is not usually used directly by a host, which instead uses the ManagerFactory.

The factory loads plugins found under paths specified in the OPENASSETIO_PLUGIN_PATH env var.

Environment Variables:
OPENASSETIO_PLUGIN_PATH str A PATH-style list of directories to search for CppPluginSystemManagerPlugin based plugins. It uses the platform-native delimiter. Searched left to right. Note that this environment variable is also used by the PythonPluginSystemManagerImplementationFactory.

Plugins are scanned and loaded lazily when required. In particular, this means no plugin scanning is done on construction.

See also
CppPluginSystem
CppPluginSystemManagerPlugin

Member Typedef Documentation

Member Function Documentation

Identifiers identifiers ( )
overridevirtual

Get a list of all manager plugin identifiers known to the factory.

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.

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.

Plugin search path(s) will be taken from the kPluginEnvVar environment variable.

Parameters
loggerLogger for progress and warnings.
Returns
New instance.
static Ptr make ( openassetio::Str  paths,
log::LoggerInterfacePtr  logger 
)
static

Construct a new instance.

The kPluginEnvVar environment variable will be ignored.

Parameters
pathsPlugin search paths.
loggerLogger for progress and warnings.
Returns
New instance.

Member Data Documentation

constexpr std::string_view kPluginEnvVar = "OPENASSETIO_PLUGIN_PATH"
static

Environment variable to read the plugin search path from.


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