LibreOffice Module ucb (master) 1
Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
UniversalContentBroker Class Reference

#include <ucb.hxx>

Inheritance diagram for UniversalContentBroker:
[legend]
Collaboration diagram for UniversalContentBroker:
[legend]

Public Member Functions

 UniversalContentBroker (const css::uno::Reference< css::uno::XComponentContext > &xContext)
 
virtual ~UniversalContentBroker () override
 
virtual OUString SAL_CALL getImplementationName () override
 
virtual sal_Bool SAL_CALL supportsService (const OUString &ServiceName) override
 
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames () override
 
virtual void SAL_CALL dispose () override
 
virtual void SAL_CALL addEventListener (const css::uno::Reference< css::lang::XEventListener > &Listener) override
 
virtual void SAL_CALL removeEventListener (const css::uno::Reference< css::lang::XEventListener > &Listener) override
 
virtual void SAL_CALL initialize (const css::uno::Sequence< css::uno::Any > &aArguments) override
 
virtual css::uno::Reference< css::ucb::XContentProvider > SAL_CALL registerContentProvider (const css::uno::Reference< css::ucb::XContentProvider > &Provider, const OUString &Scheme, sal_Bool ReplaceExisting) override
 
virtual void SAL_CALL deregisterContentProvider (const css::uno::Reference< css::ucb::XContentProvider > &Provider, const OUString &Scheme) override
 
virtual css::uno::Sequence< css::ucb::ContentProviderInfo > SAL_CALL queryContentProviders () override
 
virtual css::uno::Reference< css::ucb::XContentProvider > SAL_CALL queryContentProvider (const OUString &Identifier) override
 
virtual css::uno::Reference< css::ucb::XContent > SAL_CALL queryContent (const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier) override
 
virtual sal_Int32 SAL_CALL compareContentIds (const css::uno::Reference< css::ucb::XContentIdentifier > &Id1, const css::uno::Reference< css::ucb::XContentIdentifier > &Id2) override
 
virtual css::uno::Reference< css::ucb::XContentIdentifier > SAL_CALL createContentIdentifier (const OUString &ContentId) override
 
virtual sal_Int32 SAL_CALL createCommandIdentifier () override
 
virtual css::uno::Any SAL_CALL execute (const css::ucb::Command &aCommand, sal_Int32 CommandId, const css::uno::Reference< css::ucb::XCommandEnvironment > &Environment) override
 
virtual void SAL_CALL abort (sal_Int32 CommandId) override
 
virtual void SAL_CALL releaseCommandIdentifier (sal_Int32 aCommandId) override
 
virtual void SAL_CALL changesOccurred (const css::util::ChangesEvent &Event) override
 
virtual void SAL_CALL disposing (const css::lang::EventObject &Source) override
 

Private Member Functions

css::uno::Reference< css::ucb::XContentProvider > queryContentProvider (const OUString &Identifier, bool bResolved)
 
void globalTransfer (const css::ucb::GlobalTransferCommandArgument2 &rArg, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv)
 
css::uno::Any checkIn (const css::ucb::CheckinArgument &rArg, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv)
 
void configureUcb ()
 
bool getContentProviderData (std::u16string_view rKey1, std::u16string_view rKey2, ucbhelper::ContentProviderDataList &rListToFill)
 
void prepareAndRegister (const ucbhelper::ContentProviderDataList &rData)
 

Static Private Member Functions

static css::uno::Reference< css::ucb::XCommandInfo > getCommandInfo ()
 

Private Attributes

css::uno::Reference< css::uno::XComponentContext > m_xContext
 
css::uno::Reference< css::util::XChangesNotifier > m_xNotifier
 
css::uno::Sequence< css::uno::Any > m_aArguments
 
ProviderMap_Impl m_aProviders
 
osl::Mutex m_aMutex
 
std::unique_ptr< comphelper::OInterfaceContainerHelper3< css::lang::XEventListener > > m_pDisposeEventListeners
 
sal_Int32 m_nCommandId
 

Detailed Description

Definition at line 44 of file ucb.hxx.

Constructor & Destructor Documentation

◆ UniversalContentBroker()

UniversalContentBroker::UniversalContentBroker ( const css::uno::Reference< css::uno::XComponentContext > &  xContext)
explicit

Definition at line 224 of file ucb.cxx.

References m_xContext, and m_xContext.

◆ ~UniversalContentBroker()

UniversalContentBroker::~UniversalContentBroker ( )
overridevirtual

Definition at line 235 of file ucb.cxx.

Member Function Documentation

◆ abort()

void SAL_CALL UniversalContentBroker::abort ( sal_Int32  CommandId)
overridevirtual

Definition at line 644 of file ucb.cxx.

◆ addEventListener()

void SAL_CALL UniversalContentBroker::addEventListener ( const css::uno::Reference< css::lang::XEventListener > &  Listener)
overridevirtual

Definition at line 259 of file ucb.cxx.

References m_aMutex, and m_pDisposeEventListeners.

◆ changesOccurred()

void SAL_CALL UniversalContentBroker::changesOccurred ( const css::util::ChangesEvent &  Event)
overridevirtual

Definition at line 654 of file ucb.cxx.

References aData, and prepareAndRegister().

◆ checkIn()

uno::Any UniversalContentBroker::checkIn ( const css::ucb::CheckinArgument &  rArg,
const css::uno::Reference< css::ucb::XCommandEnvironment > &  xEnv 
)
private
Exceptions
css::uno::Exception

Definition at line 1846 of file ucbcmds.cxx.

References aCommand, ucbhelper::cancelCommandExecution(), createContentIdentifier(), comphelper::InitAnyPropertySequence(), m_xContext, queryContent(), and xTarget.

Referenced by execute().

◆ compareContentIds()

sal_Int32 SAL_CALL UniversalContentBroker::compareContentIds ( const css::uno::Reference< css::ucb::XContentIdentifier > &  Id1,
const css::uno::Reference< css::ucb::XContentIdentifier > &  Id2 
)
overridevirtual

Definition at line 480 of file ucb.cxx.

References queryContentProvider().

◆ configureUcb()

void UniversalContentBroker::configureUcb ( )
private
Exceptions
css::uno::RuntimeException

Definition at line 721 of file ucb.cxx.

References aData, getContentProviderData(), m_aArguments, prepareAndRegister(), and SAL_WARN.

Referenced by initialize().

◆ createCommandIdentifier()

sal_Int32 SAL_CALL UniversalContentBroker::createCommandIdentifier ( )
overridevirtual

Definition at line 539 of file ucb.cxx.

References m_aMutex, and m_nCommandId.

◆ createContentIdentifier()

Reference< XContentIdentifier > SAL_CALL UniversalContentBroker::createContentIdentifier ( const OUString &  ContentId)
overridevirtual

Definition at line 507 of file ucb.cxx.

References queryContentProvider().

Referenced by checkIn(), and globalTransfer().

◆ deregisterContentProvider()

void SAL_CALL UniversalContentBroker::deregisterContentProvider ( const css::uno::Reference< css::ucb::XContentProvider > &  Provider,
const OUString &  Scheme 
)
overridevirtual

◆ dispose()

void SAL_CALL UniversalContentBroker::dispose ( void  )
overridevirtual

Definition at line 244 of file ucb.cxx.

References m_pDisposeEventListeners, and m_xNotifier.

◆ disposing()

void SAL_CALL UniversalContentBroker::disposing ( const css::lang::EventObject &  Source)
overridevirtual

Definition at line 694 of file ucb.cxx.

References m_aMutex, and m_xNotifier.

◆ execute()

Any SAL_CALL UniversalContentBroker::execute ( const css::ucb::Command &  aCommand,
sal_Int32  CommandId,
const css::uno::Reference< css::ucb::XCommandEnvironment > &  Environment 
)
overridevirtual

◆ getCommandInfo()

uno::Reference< ucb::XCommandInfo > UniversalContentBroker::getCommandInfo ( )
staticprivate

Definition at line 1526 of file ucbcmds.cxx.

Referenced by execute().

◆ getContentProviderData()

bool UniversalContentBroker::getContentProviderData ( std::u16string_view  rKey1,
std::u16string_view  rKey2,
ucbhelper::ContentProviderDataList rListToFill 
)
private

◆ getImplementationName()

OUString SAL_CALL UniversalContentBroker::getImplementationName ( )
overridevirtual

Definition at line 282 of file ucb.cxx.

◆ getSupportedServiceNames()

css::uno::Sequence< OUString > SAL_CALL UniversalContentBroker::getSupportedServiceNames ( )
overridevirtual

Definition at line 290 of file ucb.cxx.

◆ globalTransfer()

void UniversalContentBroker::globalTransfer ( const css::ucb::GlobalTransferCommandArgument2 &  rArg,
const css::uno::Reference< css::ucb::XCommandEnvironment > &  xEnv 
)
private

◆ initialize()

void SAL_CALL UniversalContentBroker::initialize ( const css::uno::Sequence< css::uno::Any > &  aArguments)
overridevirtual

Definition at line 308 of file ucb.cxx.

References aArguments, Any, configureUcb(), m_aArguments, and m_aMutex.

◆ prepareAndRegister()

void UniversalContentBroker::prepareAndRegister ( const ucbhelper::ContentProviderDataList rData)
private

Definition at line 742 of file ucb.cxx.

References m_aArguments, m_xContext, and registerAtUcb().

Referenced by changesOccurred(), and configureUcb().

◆ queryContent()

Reference< XContent > SAL_CALL UniversalContentBroker::queryContent ( const css::uno::Reference< css::ucb::XContentIdentifier > &  Identifier)
overridevirtual

Definition at line 459 of file ucb.cxx.

References Identifier, and queryContentProvider().

Referenced by checkIn(), and globalTransfer().

◆ queryContentProvider() [1/2]

Reference< XContentProvider > SAL_CALL UniversalContentBroker::queryContentProvider ( const OUString &  Identifier)
overridevirtual

◆ queryContentProvider() [2/2]

Reference< XContentProvider > UniversalContentBroker::queryContentProvider ( const OUString &  Identifier,
bool  bResolved 
)
private

Definition at line 709 of file ucb.cxx.

References Identifier, m_aMutex, m_aProviders, and ucb_impl::RegexpMap< Val >::map().

◆ queryContentProviders()

css::uno::Sequence< ContentProviderInfo > SAL_CALL UniversalContentBroker::queryContentProviders ( )
overridevirtual

◆ registerContentProvider()

Reference< XContentProvider > SAL_CALL UniversalContentBroker::registerContentProvider ( const css::uno::Reference< css::ucb::XContentProvider > &  Provider,
const OUString &  Scheme,
sal_Bool  ReplaceExisting 
)
overridevirtual

◆ releaseCommandIdentifier()

void SAL_CALL UniversalContentBroker::releaseCommandIdentifier ( sal_Int32  aCommandId)
overridevirtual

Definition at line 637 of file ucb.cxx.

◆ removeEventListener()

void SAL_CALL UniversalContentBroker::removeEventListener ( const css::uno::Reference< css::lang::XEventListener > &  Listener)
overridevirtual

Definition at line 270 of file ucb.cxx.

References m_pDisposeEventListeners.

◆ supportsService()

sal_Bool SAL_CALL UniversalContentBroker::supportsService ( const OUString &  ServiceName)
overridevirtual

Definition at line 286 of file ucb.cxx.

References ServiceName, and cppu::supportsService().

Member Data Documentation

◆ m_aArguments

css::uno::Sequence< css::uno::Any > UniversalContentBroker::m_aArguments
private

Definition at line 151 of file ucb.hxx.

Referenced by configureUcb(), initialize(), and prepareAndRegister().

◆ m_aMutex

osl::Mutex UniversalContentBroker::m_aMutex
private

◆ m_aProviders

ProviderMap_Impl UniversalContentBroker::m_aProviders
private

◆ m_nCommandId

sal_Int32 UniversalContentBroker::m_nCommandId
private

Definition at line 155 of file ucb.hxx.

Referenced by createCommandIdentifier().

◆ m_pDisposeEventListeners

std::unique_ptr<comphelper::OInterfaceContainerHelper3<css::lang::XEventListener> > UniversalContentBroker::m_pDisposeEventListeners
private

Definition at line 154 of file ucb.hxx.

Referenced by addEventListener(), dispose(), and removeEventListener().

◆ m_xContext

css::uno::Reference< css::uno::XComponentContext > UniversalContentBroker::m_xContext
private

◆ m_xNotifier

css::uno::Reference< css::util::XChangesNotifier > UniversalContentBroker::m_xNotifier
private

Definition at line 149 of file ucb.hxx.

Referenced by dispose(), disposing(), and getContentProviderData().


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