LibreOffice Module scripting (master) 1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
func_provider::ProviderCache Class Reference

#include <ProviderCache.hxx>

Public Member Functions

 ProviderCache (const css::uno::Reference< css::uno::XComponentContext > &xContext, const css::uno::Sequence< css::uno::Any > &scriptContext)
 
 ProviderCache (const css::uno::Reference< css::uno::XComponentContext > &xContext, const css::uno::Sequence< css::uno::Any > &scriptContext, const css::uno::Sequence< OUString > &denyList)
 
 ~ProviderCache ()
 
css::uno::Reference< css::script::provider::XScriptProvider > getProvider (const OUString &providerName)
 
css::uno::Sequence< css::uno::Reference< css::script::provider::XScriptProvider > > getAllProviders ()
 

Private Member Functions

void populateCache ()
 
css::uno::Reference< css::script::provider::XScriptProvider > createProvider (ProviderDetails &details)
 
bool isInDenyList (const OUString &serviceName) const
 

Private Attributes

css::uno::Sequence< OUString > m_sDenyList
 
ProviderDetails_hash m_hProviderDetailsCache
 
std::mutex m_mutex
 
css::uno::Sequence< css::uno::Any > m_Sctx
 
css::uno::Reference< css::uno::XComponentContext > m_xContext
 
css::uno::Reference< css::lang::XMultiComponentFactory > m_xMgr
 

Detailed Description

Definition at line 46 of file ProviderCache.hxx.

Constructor & Destructor Documentation

◆ ProviderCache() [1/2]

func_provider::ProviderCache::ProviderCache ( const css::uno::Reference< css::uno::XComponentContext > &  xContext,
const css::uno::Sequence< css::uno::Any > &  scriptContext 
)
Exceptions
css::uno::RuntimeException

◆ ProviderCache() [2/2]

func_provider::ProviderCache::ProviderCache ( const css::uno::Reference< css::uno::XComponentContext > &  xContext,
const css::uno::Sequence< css::uno::Any > &  scriptContext,
const css::uno::Sequence< OUString > &  denyList 
)
Exceptions
css::uno::RuntimeException

◆ ~ProviderCache()

func_provider::ProviderCache::~ProviderCache ( )

Definition at line 58 of file ProviderCache.cxx.

Member Function Documentation

◆ createProvider()

Reference< provider::XScriptProvider > func_provider::ProviderCache::createProvider ( ProviderDetails details)
private

◆ getAllProviders()

Sequence< Reference< provider::XScriptProvider > > func_provider::ProviderCache::getAllProviders ( )
Exceptions
css::uno::RuntimeException

Definition at line 84 of file ProviderCache.cxx.

References DBG_UNHANDLED_EXCEPTION, Exception, m_mutex, and SAL_WARN.

Referenced by func_provider::MasterScriptProvider::getChildNodes().

◆ getProvider()

Reference< provider::XScriptProvider > func_provider::ProviderCache::getProvider ( const OUString &  providerName)

Definition at line 63 of file ProviderCache.cxx.

References m_mutex.

◆ isInDenyList()

bool func_provider::ProviderCache::isInDenyList ( const OUString &  serviceName) const
private

Definition at line 197 of file ProviderCache.cxx.

References comphelper::findValue().

◆ populateCache()

void func_provider::ProviderCache::populateCache ( )
private
Exceptions
css::uno::RuntimeException

Definition at line 132 of file ProviderCache.cxx.

References Exception, func_provider::ProviderDetails::factory, cppu::getCaughtException(), m_mutex, and pName.

Member Data Documentation

◆ m_hProviderDetailsCache

ProviderDetails_hash func_provider::ProviderCache::m_hProviderDetailsCache
private

Definition at line 70 of file ProviderCache.hxx.

◆ m_mutex

std::mutex func_provider::ProviderCache::m_mutex
private

Definition at line 71 of file ProviderCache.hxx.

◆ m_Sctx

css::uno::Sequence< css::uno::Any > func_provider::ProviderCache::m_Sctx
private

Definition at line 72 of file ProviderCache.hxx.

◆ m_sDenyList

css::uno::Sequence< OUString > func_provider::ProviderCache::m_sDenyList
private

Definition at line 69 of file ProviderCache.hxx.

◆ m_xContext

css::uno::Reference< css::uno::XComponentContext > func_provider::ProviderCache::m_xContext
private

Definition at line 73 of file ProviderCache.hxx.

◆ m_xMgr

css::uno::Reference< css::lang::XMultiComponentFactory > func_provider::ProviderCache::m_xMgr
private

Definition at line 74 of file ProviderCache.hxx.


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