NAP
Public Member Functions | List of all members
ModuleCache::Handle Class Referencefinal

#include <nap/modulecache.h>

Public Member Functions

const nap::ModulesourceModule (const ProjectInfo &projectinfo, const std::string &moduleName, utility::ErrorState &err)
 
 Handle (Handle &)=delete
 
Handleoperator= (const Handle &)=delete
 
 Handle (Handle &&other) noexcept
 
Handleoperator= (Handle &&other) noexcept
 

Description

Unique handle to this process module cache. Any other thread that wants to source a module must wait until this handle is destroyed and the lock released.

Constructor & Destructor Documentation

◆ Handle() [1/2]

Handle ( Handle )
delete

◆ Handle() [2/2]

Handle ( Handle &&  other)
noexcept

Member Function Documentation

◆ operator=() [1/2]

Handle& operator= ( const Handle )
delete

◆ operator=() [2/2]

Handle& operator= ( Handle &&  other)
noexcept

◆ sourceModule()

const nap::Module* sourceModule ( const ProjectInfo projectinfo,
const std::string &  moduleName,
utility::ErrorState err 
)

Attempts to find and load a module into the current NAP process, including all module dependencies.

Parameters
projectinfoproject information resource
moduleNamename of the module to load
errcontains the error if loading operation fails
Returns
if loading the module succeeded