LibreOffice Module cppuhelper (master) 1
|
#include <servicemanager.hxx>
Classes | |
struct | Data |
Public Member Functions | |
ServiceManager () | |
ServiceManager (const ServiceManager &)=delete | |
const ServiceManager & | operator= (const ServiceManager &)=delete |
void | init (std::u16string_view rdbUris) |
void | setContext (css::uno::Reference< css::uno::XComponentContext > const &context) |
void | addSingletonContextEntries (std::vector< cppu::ContextEntry_Init > *entries) |
css::uno::Reference< css::uno::XComponentContext > const & | getContext () const |
void | loadImplementation (css::uno::Reference< css::uno::XComponentContext > const &context, std::shared_ptr< Data::Implementation > const &implementation) |
virtual void SAL_CALL | acquire () noexcept override |
increasing m_refCount More... | |
virtual void SAL_CALL | release () noexcept override |
decreasing m_refCount More... | |
Public Member Functions inherited from cppuhelper::WeakComponentImplHelper2< Ifc > | |
virtual void SAL_CALL | acquire () noexcept override |
increasing m_refCount More... | |
virtual void SAL_CALL | release () noexcept override |
decreasing m_refCount More... | |
virtual void SAL_CALL | dispose () noexcept final override |
virtual void SAL_CALL | addEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) final override |
virtual void SAL_CALL | removeEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) final override |
virtual css::uno::Any SAL_CALL | queryInterface (css::uno::Type const &rType) override |
Basic queryInterface() implementation supporting com::sun::star::uno::XWeak and com::sun::star::uno::XInterface. More... | |
virtual css::uno::Sequence< css::uno::Type > SAL_CALL | getTypes () override |
virtual css::uno::Sequence< sal_Int8 > SAL_CALL | getImplementationId () override |
Public Member Functions inherited from cppuhelper::WeakComponentImplHelperBase2 | |
virtual | ~WeakComponentImplHelperBase2 () override |
virtual void SAL_CALL | dispose () override |
virtual void SAL_CALL | addEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) override |
virtual void SAL_CALL | removeEventListener (css::uno::Reference< css::lang::XEventListener > const &rxListener) override |
virtual css::uno::Any SAL_CALL | queryInterface (css::uno::Type const &rType) override |
Basic queryInterface() implementation supporting com::sun::star::uno::XWeak and com::sun::star::uno::XInterface. More... | |
virtual void | disposing (std::unique_lock< std::mutex > &) |
Called by dispose for subclasses to do dispose() work. More... | |
Public Member Functions inherited from cppuhelper::UnoImplBase | |
virtual | ~UnoImplBase () |
Public Member Functions inherited from cppu::OWeakObject | |
OWeakObject () | |
Default Constructor. More... | |
OWeakObject (const OWeakObject &) | |
Dummy copy constructor. More... | |
OWeakObject &SAL_CALL | operator= (const OWeakObject &) |
Dummy assignment operator. More... | |
virtual css::uno::Any SAL_CALL | queryInterface (const css::uno::Type &rType) SAL_OVERRIDE |
Basic queryInterface() implementation supporting com::sun::star::uno::XWeak and com::sun::star::uno::XInterface. More... | |
virtual void SAL_CALL | acquire () SAL_NOEXCEPT SAL_OVERRIDE |
increasing m_refCount More... | |
virtual void SAL_CALL | release () SAL_NOEXCEPT SAL_OVERRIDE |
decreasing m_refCount More... | |
virtual css::uno::Reference< css::uno::XAdapter > SAL_CALL | queryAdapter () SAL_OVERRIDE |
XWeak::queryAdapter() implementation. More... | |
SAL_CALL | operator css::uno::Reference< css::uno::XInterface > () |
Cast operator to XInterface reference. More... | |
Private Member Functions | |
virtual | ~ServiceManager () override |
virtual void | disposing (std::unique_lock< std::mutex > &) override |
Called by dispose for subclasses to do dispose() work. More... | |
virtual OUString SAL_CALL | getImplementationName () override |
virtual sal_Bool SAL_CALL | supportsService (OUString const &ServiceName) override |
virtual css::uno::Sequence< OUString > SAL_CALL | getSupportedServiceNames () override |
virtual css::uno::Reference< css::uno::XInterface > SAL_CALL | createInstance (OUString const &aServiceSpecifier) override |
virtual css::uno::Reference< css::uno::XInterface > SAL_CALL | createInstanceWithArguments (OUString const &ServiceSpecifier, css::uno::Sequence< css::uno::Any > const &Arguments) override |
virtual css::uno::Sequence< OUString > SAL_CALL | getAvailableServiceNames () override |
virtual css::uno::Reference< css::uno::XInterface > SAL_CALL | createInstanceWithContext (OUString const &aServiceSpecifier, css::uno::Reference< css::uno::XComponentContext > const &Context) override |
virtual css::uno::Reference< css::uno::XInterface > SAL_CALL | createInstanceWithArgumentsAndContext (OUString const &ServiceSpecifier, css::uno::Sequence< css::uno::Any > const &Arguments, css::uno::Reference< css::uno::XComponentContext > const &Context) override |
virtual css::uno::Type SAL_CALL | getElementType () override |
virtual sal_Bool SAL_CALL | hasElements () override |
virtual css::uno::Reference< css::container::XEnumeration > SAL_CALL | createEnumeration () override |
virtual sal_Bool SAL_CALL | has (css::uno::Any const &aElement) override |
virtual void SAL_CALL | insert (css::uno::Any const &aElement) override |
virtual void SAL_CALL | remove (css::uno::Any const &aElement) override |
virtual css::uno::Reference< css::container::XEnumeration > SAL_CALL | createContentEnumeration (OUString const &aServiceName) override |
virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL | getPropertySetInfo () override |
virtual void SAL_CALL | setPropertyValue (OUString const &aPropertyName, css::uno::Any const &aValue) override |
virtual css::uno::Any SAL_CALL | getPropertyValue (OUString const &PropertyName) override |
virtual void SAL_CALL | addPropertyChangeListener (OUString const &aPropertyName, css::uno::Reference< css::beans::XPropertyChangeListener > const &xListener) override |
virtual void SAL_CALL | removePropertyChangeListener (OUString const &aPropertyName, css::uno::Reference< css::beans::XPropertyChangeListener > const &aListener) override |
virtual void SAL_CALL | addVetoableChangeListener (OUString const &PropertyName, css::uno::Reference< css::beans::XVetoableChangeListener > const &aListener) override |
virtual void SAL_CALL | removeVetoableChangeListener (OUString const &PropertyName, css::uno::Reference< css::beans::XVetoableChangeListener > const &aListener) override |
virtual css::uno::Sequence< css::beans::Property > SAL_CALL | getProperties () override |
virtual css::beans::Property SAL_CALL | getPropertyByName (OUString const &aName) override |
virtual sal_Bool SAL_CALL | hasPropertyByName (OUString const &Name) override |
virtual void SAL_CALL | disposing (css::lang::EventObject const &Source) override |
virtual void SAL_CALL | initialize (css::uno::Sequence< css::uno::Any > const &aArguments) override |
void | removeEventListenerFromComponent (css::uno::Reference< css::lang::XComponent > const &component) |
void | readRdbDirectory (std::u16string_view uri, bool optional) |
void | readRdbFile (OUString const &uri, bool optional) |
bool | readLegacyRdbFile (OUString const &uri) |
OUString | readLegacyRdbString (std::u16string_view uri, RegistryKey &key, OUString const &path) |
void | readLegacyRdbStrings (std::u16string_view uri, RegistryKey &key, OUString const &path, std::vector< OUString > *strings) |
void | insertRdbFiles (std::vector< OUString > const &uris, css::uno::Reference< css::uno::XComponentContext > const &alientContext) |
void | insertLegacyFactory (css::uno::Reference< css::lang::XServiceInfo > const &factoryInfo) |
bool | insertExtraData (Data const &extra) |
void | removeRdbFiles (std::vector< OUString > const &uris) |
bool | removeLegacyFactory (css::uno::Reference< css::lang::XServiceInfo > const &factoryInfo, bool removeListener) |
void | removeImplementation (const OUString &name) |
std::shared_ptr< Data::Implementation > | findServiceImplementation (css::uno::Reference< css::uno::XComponentContext > const &context, OUString const &specifier) |
void | preloadImplementations () |
Used only by LibreOfficeKit when used by Online to pre-initialize. More... | |
Private Attributes | |
css::uno::Reference< css::uno::XComponentContext > | context_ |
Data | data_ |
Additional Inherited Members | |
Protected Member Functions inherited from cppuhelper::WeakComponentImplHelperBase2 | |
void | throwIfDisposed (std::unique_lock< std::mutex > &) |
Protected Member Functions inherited from cppu::OWeakObject | |
virtual | ~OWeakObject () COVERITY_NOEXCEPT_FALSE |
Virtual dtor. More... | |
void | disposeWeakConnectionPoint () |
disposes and resets m_pWeakConnectionPoint More... | |
Protected Attributes inherited from cppuhelper::WeakComponentImplHelperBase2 | |
OInterfaceContainerHelper4< css::lang::XEventListener > | maEventListeners |
Protected Attributes inherited from cppuhelper::UnoImplBase | |
std::mutex | m_aMutex |
bool | m_bDisposed = false |
Protected Attributes inherited from cppu::OWeakObject | |
oslInterlockedCount | m_refCount |
reference count. More... | |
Definition at line 64 of file servicemanager.hxx.
|
inline |
Definition at line 186 of file servicemanager.hxx.
|
delete |
|
overrideprivatevirtual |
Definition at line 1286 of file servicemanager.cxx.
|
inlineoverridevirtualnoexcept |
increasing m_refCount
Reimplemented from cppuhelper::WeakComponentImplHelper2< Ifc >.
Definition at line 80 of file cppuhelper/inc/compbase2.hxx.
|
overrideprivatevirtual |
Definition at line 1213 of file servicemanager.cxx.
References cppuhelper::WeakComponentImplHelper2< Ifc >::addEventListener().
void cppuhelper::ServiceManager::addSingletonContextEntries | ( | std::vector< cppu::ContextEntry_Init > * | entries | ) |
Definition at line 770 of file servicemanager.cxx.
References data_, SAL_INFO_IF, and cppuhelper::ServiceManager::Data::singletons.
|
overrideprivatevirtual |
Definition at line 1239 of file servicemanager.cxx.
References cppuhelper::WeakComponentImplHelper2< Ifc >::addEventListener().
|
overrideprivatevirtual |
Definition at line 1137 of file servicemanager.cxx.
References data_, i, cppuhelper::UnoImplBase::m_aMutex, cppuhelper::UnoImplBase::m_bDisposed, cppuhelper::ServiceManager::Data::services, cppuhelper::ServiceManager::Data::Implementation::STATUS_NEW, and cppuhelper::ServiceManager::Data::Implementation::STATUS_WRAPPER.
|
overrideprivatevirtual |
Definition at line 1036 of file servicemanager.cxx.
|
overrideprivatevirtual |
Definition at line 967 of file servicemanager.cxx.
References context_, and createInstanceWithContext().
|
overrideprivatevirtual |
Definition at line 975 of file servicemanager.cxx.
References context_, and createInstanceWithArgumentsAndContext().
|
overrideprivatevirtual |
Definition at line 1011 of file servicemanager.cxx.
References findServiceImplementation().
Referenced by createInstanceWithArguments().
|
overrideprivatevirtual |
Definition at line 1000 of file servicemanager.cxx.
References findServiceImplementation().
Referenced by createInstance().
|
overrideprivatevirtual |
Definition at line 1288 of file servicemanager.cxx.
References removeLegacyFactory(), and Source.
|
overrideprivatevirtual |
Called by dispose for subclasses to do dispose() work.
The mutex is held when called, and subclasses can unlock() the guard if necessary.
Reimplemented from cppuhelper::WeakComponentImplHelperBase2.
Definition at line 885 of file servicemanager.cxx.
References data_, cppuhelper::ServiceManager::Data::dynamicImplementations, cppuhelper::ServiceManager::Data::namedImplementations, removeEventListenerFromComponent(), SAL_WARN, cppuhelper::ServiceManager::Data::services, and cppuhelper::ServiceManager::Data::singletons.
|
private |
Definition at line 1749 of file servicemanager.cxx.
References data_, i, loadImplementation(), cppuhelper::UnoImplBase::m_aMutex, cppuhelper::ServiceManager::Data::namedImplementations, SAL_INFO, SAL_INFO_IF, cppuhelper::ServiceManager::Data::services, and cppuhelper::ServiceManager::Data::Implementation::STATUS_LOADED.
Referenced by createInstanceWithArgumentsAndContext(), and createInstanceWithContext().
|
overrideprivatevirtual |
Definition at line 985 of file servicemanager.cxx.
References data_, cppuhelper::UnoImplBase::m_aMutex, cppuhelper::UnoImplBase::m_bDisposed, o3tl::make_unsigned(), comphelper::mapKeysToSequence(), SAL_MAX_INT32, and cppuhelper::ServiceManager::Data::services.
|
inline |
Definition at line 207 of file servicemanager.hxx.
References context_.
|
overrideprivatevirtual |
Definition at line 1022 of file servicemanager.cxx.
|
overrideprivatevirtual |
Definition at line 948 of file servicemanager.cxx.
|
overrideprivatevirtual |
Definition at line 1266 of file servicemanager.cxx.
|
overrideprivatevirtual |
Definition at line 1270 of file servicemanager.cxx.
References aName.
|
overrideprivatevirtual |
Definition at line 1185 of file servicemanager.cxx.
|
overrideprivatevirtual |
Definition at line 1202 of file servicemanager.cxx.
References context_.
|
overrideprivatevirtual |
Definition at line 961 of file servicemanager.cxx.
|
overrideprivatevirtual |
Definition at line 1043 of file servicemanager.cxx.
|
overrideprivatevirtual |
Definition at line 1027 of file servicemanager.cxx.
References data_, cppuhelper::ServiceManager::Data::dynamicImplementations, cppuhelper::UnoImplBase::m_aMutex, and cppuhelper::ServiceManager::Data::namedImplementations.
|
overrideprivatevirtual |
Definition at line 1280 of file servicemanager.cxx.
References Name.
void cppuhelper::ServiceManager::init | ( | std::u16string_view | rdbUris | ) |
Definition at line 1310 of file servicemanager.cxx.
References cppu::decodeRdbUri(), o3tl::getToken(), i, readRdbDirectory(), and readRdbFile().
Referenced by cppuhelper::ServiceManager::Data::Implementation::doCreateInstanceWithArguments().
|
overrideprivatevirtual |
Definition at line 934 of file servicemanager.cxx.
References aArguments, and preloadImplementations().
|
overrideprivatevirtual |
Definition at line 1050 of file servicemanager.cxx.
References args, insertLegacyFactory(), and insertRdbFiles().
|
private |
Definition at line 1574 of file servicemanager.cxx.
References context_, data_, cppuhelper::ServiceManager::Data::dynamicImplementations, i, cppuhelper::UnoImplBase::m_aMutex, cppuhelper::UnoImplBase::m_bDisposed, name, cppuhelper::ServiceManager::Data::namedImplementations, SAL_INFO, SAL_INFO_IF, cppuhelper::ServiceManager::Data::services, and cppuhelper::ServiceManager::Data::singletons.
Referenced by insertLegacyFactory(), and insertRdbFiles().
|
private |
Definition at line 1537 of file servicemanager.cxx.
References comp, cppuhelper::ServiceManager::Data::dynamicImplementations, i, insertExtraData(), name, cppuhelper::ServiceManager::Data::namedImplementations, and cppuhelper::ServiceManager::Data::services.
Referenced by insert().
|
private |
Definition at line 1515 of file servicemanager.cxx.
References insertExtraData().
Referenced by insert().
void cppuhelper::ServiceManager::loadImplementation | ( | css::uno::Reference< css::uno::XComponentContext > const & | context, |
std::shared_ptr< Data::Implementation > const & | implementation | ||
) |
Definition at line 792 of file servicemanager.cxx.
References cppu::bootstrap_expandUri(), loader, cppuhelper::detail::loadSharedLibComponentFactory(), cppuhelper::UnoImplBase::m_aMutex, cppuhelper::UnoImplBase::m_bDisposed, SAL_WARN_IF, and cppuhelper::ServiceManager::Data::Implementation::STATUS_LOADED.
Referenced by findServiceImplementation().
|
delete |
|
private |
Used only by LibreOfficeKit when used by Online to pre-initialize.
Allow external callers & testers to disable certain components
Definition at line 1813 of file servicemanager.cxx.
References cppu::bootstrap_expandUri(), COMPONENT_GETFACTORY, data_, cppuhelper::detail::getEnvironment(), i, cppuhelper::UnoImplBase::m_aMutex, cppuhelper::ServiceManager::Data::namedImplementations, OUStringToOString(), simplifyModule(), cppuhelper::ServiceManager::Data::Implementation::STATUS_LOADED, and xFactory.
Referenced by initialize().
|
private |
Definition at line 1380 of file servicemanager.cxx.
References data_, RegistryKeyArray::getElement(), RegistryKeyArray::getLength(), RegistryKey::getName(), i, name, cppuhelper::ServiceManager::Data::namedImplementations, Registry::open(), Registry::openRootKey(), RegistryKey::openSubKeys(), readLegacyRdbString(), readLegacyRdbStrings(), cppuhelper::ServiceManager::Data::services, and cppuhelper::ServiceManager::Data::singletons.
Referenced by readRdbFile().
|
private |
Definition at line 1453 of file servicemanager.cxx.
References RegistryKey::getValue(), RegistryKey::getValueInfo(), o3tl::make_unsigned(), RegistryKey::openKey(), RegValueType, SAL_MAX_INT32, t, and v.
Referenced by readLegacyRdbFile().
|
private |
Definition at line 1486 of file servicemanager.cxx.
References RegistryKeyNames::getElement(), RegistryKey::getKeyNames(), RegistryKeyNames::getLength(), RegistryKey::getName(), i, RegistryKey::openKey(), and prefix.
Referenced by readLegacyRdbFile().
|
private |
Definition at line 1327 of file servicemanager.cxx.
References cppu::nextDirectoryItem(), readRdbFile(), and SAL_INFO.
Referenced by init().
|
private |
Definition at line 1354 of file servicemanager.cxx.
References data_, readLegacyRdbFile(), and SAL_INFO.
Referenced by init(), and readRdbDirectory().
|
inlineoverridevirtualnoexcept |
decreasing m_refCount
Reimplemented from cppuhelper::WeakComponentImplHelper2< Ifc >.
Definition at line 82 of file cppuhelper/inc/compbase2.hxx.
|
overrideprivatevirtual |
Definition at line 1095 of file servicemanager.cxx.
References args, i, removeImplementation(), removeLegacyFactory(), and removeRdbFiles().
|
private |
Definition at line 1297 of file servicemanager.cxx.
References SAL_INFO.
Referenced by disposing(), and removeLegacyFactory().
|
private |
Definition at line 1717 of file servicemanager.cxx.
References data_, cppuhelper::ServiceManager::Data::dynamicImplementations, i, cppuhelper::UnoImplBase::m_aMutex, cppuhelper::UnoImplBase::m_bDisposed, name, cppuhelper::ServiceManager::Data::namedImplementations, cppuhelper::ServiceManager::Data::services, and cppuhelper::ServiceManager::Data::singletons.
Referenced by remove().
|
private |
Definition at line 1682 of file servicemanager.cxx.
References comp, data_, cppuhelper::ServiceManager::Data::dynamicImplementations, i, cppuhelper::UnoImplBase::m_aMutex, cppuhelper::UnoImplBase::m_bDisposed, cppuhelper::ServiceManager::Data::namedImplementations, removeEventListenerFromComponent(), removeListener(), cppuhelper::ServiceManager::Data::services, and cppuhelper::ServiceManager::Data::singletons.
Referenced by disposing(), and remove().
|
overrideprivatevirtual |
Definition at line 1226 of file servicemanager.cxx.
References cppuhelper::WeakComponentImplHelper2< Ifc >::removeEventListener().
|
private |
Definition at line 1647 of file servicemanager.cxx.
References data_, cppuhelper::UnoImplBase::m_aMutex, cppuhelper::ServiceManager::Data::namedImplementations, cppuhelper::ServiceManager::Data::services, and cppuhelper::ServiceManager::Data::singletons.
Referenced by remove().
|
overrideprivatevirtual |
Definition at line 1252 of file servicemanager.cxx.
References cppuhelper::WeakComponentImplHelper2< Ifc >::removeEventListener().
|
inline |
Definition at line 196 of file servicemanager.hxx.
References context_.
|
overrideprivatevirtual |
Definition at line 1190 of file servicemanager.cxx.
|
overrideprivatevirtual |
Definition at line 954 of file servicemanager.cxx.
References ServiceName, and cppu::supportsService().
|
private |
Definition at line 351 of file servicemanager.hxx.
Referenced by createInstance(), createInstanceWithArguments(), getContext(), getPropertyValue(), insertExtraData(), and setContext().
|
private |
Definition at line 352 of file servicemanager.hxx.
Referenced by addSingletonContextEntries(), createContentEnumeration(), disposing(), findServiceImplementation(), getAvailableServiceNames(), hasElements(), insertExtraData(), preloadImplementations(), readLegacyRdbFile(), readRdbFile(), removeImplementation(), removeLegacyFactory(), and removeRdbFiles().