LibreOffice Module ucb (master) 1
Public Member Functions | Private Types | Private Member Functions | Private Attributes | Friends | List of all members
fileaccess::BaseContent Class Reference

#include <bc.hxx>

Inheritance diagram for fileaccess::BaseContent:
[legend]
Collaboration diagram for fileaccess::BaseContent:
[legend]

Public Member Functions

 BaseContent (TaskManager *pMyShell, const css::uno::Reference< css::ucb::XContentIdentifier > &xContentIdentifier, const OUString &aUnqPath)
 
virtual ~BaseContent () override
 
virtual void SAL_CALL dispose () override
 
virtual void SAL_CALL addEventListener (const css::uno::Reference< css::lang::XEventListener > &xListener) override
 
virtual void SAL_CALL removeEventListener (const css::uno::Reference< css::lang::XEventListener > &aListener) 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 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 css::uno::Reference< css::ucb::XContentIdentifier > SAL_CALL getIdentifier () override
 
virtual OUString SAL_CALL getContentType () override
 
virtual void SAL_CALL addContentEventListener (const css::uno::Reference< css::ucb::XContentEventListener > &Listener) override
 
virtual void SAL_CALL removeContentEventListener (const css::uno::Reference< css::ucb::XContentEventListener > &Listener) override
 
virtual void SAL_CALL addPropertiesChangeListener (const css::uno::Sequence< OUString > &PropertyNames, const css::uno::Reference< css::beans::XPropertiesChangeListener > &Listener) override
 
virtual void SAL_CALL removePropertiesChangeListener (const css::uno::Sequence< OUString > &PropertyNames, const css::uno::Reference< css::beans::XPropertiesChangeListener > &Listener) override
 
virtual void SAL_CALL addProperty (const OUString &Name, sal_Int16 Attributes, const css::uno::Any &DefaultValue) override
 
virtual void SAL_CALL removeProperty (const OUString &Name) override
 
virtual void SAL_CALL addPropertySetInfoChangeListener (const css::uno::Reference< css::beans::XPropertySetInfoChangeListener > &Listener) override
 
virtual void SAL_CALL removePropertySetInfoChangeListener (const css::uno::Reference< css::beans::XPropertySetInfoChangeListener > &Listener) override
 
virtual css::uno::Sequence< css::ucb::ContentInfo > SAL_CALL queryCreatableContentsInfo () override
 
virtual css::uno::Reference< css::ucb::XContent > SAL_CALL createNewContent (const css::ucb::ContentInfo &Info) override
 
virtual css::uno::Reference< css::uno::XInterface > SAL_CALL getParent () override
 
virtual void SAL_CALL setParent (const css::uno::Reference< css::uno::XInterface > &Parent) override
 
std::optional< ContentEventNotifiercDEL () override
 
std::optional< ContentEventNotifiercEXC (const OUString &aNewName) override
 
std::optional< ContentEventNotifiercCEL () override
 
std::optional< PropertySetInfoChangeNotifiercPSL () override
 
std::optional< PropertyChangeNotifiercPCL () override
 
virtual std::optional< ContentEventNotifiercEXC (const OUString &aNewName)=0
 
virtual std::optional< ContentEventNotifiercDEL ()=0
 
virtual std::optional< ContentEventNotifiercCEL ()=0
 
virtual std::optional< PropertySetInfoChangeNotifiercPSL ()=0
 
virtual std::optional< PropertyChangeNotifiercPCL ()=0
 

Private Types

enum  state {
  NameForInsertionSet = 1 ,
  JustInserted = 2 ,
  Deleted = 4 ,
  FullFeatured = 8
}
 

Private Member Functions

 BaseContent (TaskManager *pMyShell, const OUString &parentName, bool bFolder)
 
css::uno::Reference< css::ucb::XCommandInfo > getCommandInfo ()
 
css::uno::Reference< css::beans::XPropertySetInfo > getPropertySetInfo ()
 
css::uno::Reference< css::sdbc::XRow > getPropertyValues (sal_Int32 nMyCommandIdentifier, const css::uno::Sequence< css::beans::Property > &PropertySet)
 
css::uno::Sequence< css::uno::Any > setPropertyValues (sal_Int32 nMyCommandIdentifier, const css::uno::Sequence< css::beans::PropertyValue > &Values)
 
css::uno::Reference< css::ucb::XDynamicResultSet > open (sal_Int32 nMyCommandIdentifier, const css::ucb::OpenCommandArgument2 &aCommandArgument)
 
void deleteContent (sal_Int32 nMyCommandIdentifier)
 
void transfer (sal_Int32 nMyCommandIdentifier, const css::ucb::TransferInfo &aTransferInfo)
 
void insert (sal_Int32 nMyCommandIdentifier, const css::ucb::InsertCommandArgument &aInsertArgument)
 
void endTask (sal_Int32 CommandId)
 

Private Attributes

TaskManagerm_pMyShell
 
css::uno::Reference< css::ucb::XContentIdentifier > m_xContentIdentifier
 
OUString m_aUncPath
 
bool m_bFolder
 
sal_uInt16 m_nState
 
std::mutex m_aMutex
 
comphelper::OInterfaceContainerHelper4< css::lang::XEventListener > m_aDisposeEventListeners
 
comphelper::OInterfaceContainerHelper4< css::ucb::XContentEventListener > m_aContentEventListeners
 
comphelper::OInterfaceContainerHelper4< css::beans::XPropertySetInfoChangeListener > m_aPropertySetInfoChangeListeners
 
std::unique_ptr< PropertyListenersm_pPropertyListener
 

Friends

class ContentEventNotifier
 

Additional Inherited Members

- Protected Member Functions inherited from fileaccess::Notifier
 ~Notifier ()
 

Detailed Description

Definition at line 54 of file bc.hxx.

Member Enumeration Documentation

◆ state

Enumerator
NameForInsertionSet 
JustInserted 
Deleted 
FullFeatured 

Definition at line 199 of file bc.hxx.

Constructor & Destructor Documentation

◆ BaseContent() [1/2]

BaseContent::BaseContent ( TaskManager pMyShell,
const OUString &  parentName,
bool  bFolder 
)
private

Definition at line 110 of file bc.cxx.

References m_pMyShell, and fileaccess::TaskManager::m_pProvider.

Referenced by createNewContent().

◆ BaseContent() [2/2]

fileaccess::BaseContent::BaseContent ( TaskManager pMyShell,
const css::uno::Reference< css::ucb::XContentIdentifier > &  xContentIdentifier,
const OUString &  aUnqPath 
)

◆ ~BaseContent()

BaseContent::~BaseContent ( )
overridevirtual

Member Function Documentation

◆ abort()

void SAL_CALL BaseContent::abort ( sal_Int32  CommandId)
overridevirtual

Definition at line 221 of file bc.cxx.

◆ addContentEventListener()

void SAL_CALL BaseContent::addContentEventListener ( const css::uno::Reference< css::ucb::XContentEventListener > &  Listener)
overridevirtual

◆ addEventListener()

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

◆ addPropertiesChangeListener()

void SAL_CALL BaseContent::addPropertiesChangeListener ( const css::uno::Sequence< OUString > &  PropertyNames,
const css::uno::Reference< css::beans::XPropertiesChangeListener > &  Listener 
)
overridevirtual

◆ addProperty()

void SAL_CALL BaseContent::addProperty ( const OUString &  Name,
sal_Int16  Attributes,
const css::uno::Any &  DefaultValue 
)
overridevirtual

◆ addPropertySetInfoChangeListener()

void SAL_CALL BaseContent::addPropertySetInfoChangeListener ( const css::uno::Reference< css::beans::XPropertySetInfoChangeListener > &  Listener)
overridevirtual

◆ cCEL()

std::optional< ContentEventNotifier > BaseContent::cCEL ( )
overridevirtual

◆ cDEL()

std::optional< ContentEventNotifier > BaseContent::cDEL ( )
overridevirtual

◆ cEXC()

std::optional< ContentEventNotifier > BaseContent::cEXC ( const OUString &  aNewName)
overridevirtual

◆ cPCL()

std::optional< PropertyChangeNotifier > BaseContent::cPCL ( )
overridevirtual

◆ cPSL()

std::optional< PropertySetInfoChangeNotifier > BaseContent::cPSL ( )
overridevirtual

◆ createCommandIdentifier()

sal_Int32 SAL_CALL BaseContent::createCommandIdentifier ( )
overridevirtual

Definition at line 214 of file bc.cxx.

References fileaccess::TaskManager::getCommandId(), and m_pMyShell.

Referenced by execute().

◆ createNewContent()

Reference< XContent > SAL_CALL BaseContent::createNewContent ( const css::ucb::ContentInfo &  Info)
overridevirtual

◆ deleteContent()

void BaseContent::deleteContent ( sal_Int32  nMyCommandIdentifier)
private

Definition at line 890 of file bc.cxx.

References Deleted, m_aMutex, m_aUncPath, m_nState, m_pMyShell, and fileaccess::TaskManager::remove().

Referenced by execute().

◆ dispose()

void SAL_CALL BaseContent::dispose ( void  )
overridevirtual

◆ endTask()

void BaseContent::endTask ( sal_Int32  CommandId)
private

Definition at line 1079 of file bc.cxx.

References fileaccess::TaskManager::endTask(), m_aUncPath, and m_pMyShell.

Referenced by execute(), and setPropertyValues().

◆ execute()

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

◆ getCommandInfo()

Reference< XCommandInfo > BaseContent::getCommandInfo ( )
private
Exceptions
css::uno::RuntimeException

Definition at line 607 of file bc.cxx.

References Deleted, fileaccess::TaskManager::info_c(), m_nState, and m_pMyShell.

Referenced by execute().

◆ getContentType()

OUString SAL_CALL BaseContent::getContentType ( )
overridevirtual

◆ getIdentifier()

Reference< ucb::XContentIdentifier > SAL_CALL BaseContent::getIdentifier ( )
overridevirtual

Definition at line 385 of file bc.cxx.

References m_xContentIdentifier.

◆ getImplementationName()

OUString SAL_CALL BaseContent::getImplementationName ( )
overridevirtual

Definition at line 192 of file bc.cxx.

◆ getParent()

Reference< XInterface > SAL_CALL BaseContent::getParent ( )
overridevirtual

◆ getPropertySetInfo()

Reference< beans::XPropertySetInfo > BaseContent::getPropertySetInfo ( )
private
Exceptions
css::uno::RuntimeException

Definition at line 617 of file bc.cxx.

References Deleted, fileaccess::TaskManager::info_p(), m_aUncPath, m_nState, and m_pMyShell.

Referenced by execute().

◆ getPropertyValues()

Reference< sdbc::XRow > BaseContent::getPropertyValues ( sal_Int32  nMyCommandIdentifier,
const css::uno::Sequence< css::beans::Property > &  PropertySet 
)
private

◆ getSupportedServiceNames()

Sequence< OUString > SAL_CALL BaseContent::getSupportedServiceNames ( )
overridevirtual

Definition at line 204 of file bc.cxx.

◆ insert()

void BaseContent::insert ( sal_Int32  nMyCommandIdentifier,
const css::ucb::InsertCommandArgument &  aInsertArgument 
)
private

◆ open()

Reference< XDynamicResultSet > BaseContent::open ( sal_Int32  nMyCommandIdentifier,
const css::ucb::OpenCommandArgument2 &  aCommandArgument 
)
private

◆ queryCreatableContentsInfo()

Sequence< ContentInfo > SAL_CALL BaseContent::queryCreatableContentsInfo ( )
overridevirtual

Definition at line 487 of file bc.cxx.

References fileaccess::TaskManager::queryCreatableContentsInfo().

◆ removeContentEventListener()

void SAL_CALL BaseContent::removeContentEventListener ( const css::uno::Reference< css::ucb::XContentEventListener > &  Listener)
overridevirtual

◆ removeEventListener()

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

◆ removePropertiesChangeListener()

void SAL_CALL BaseContent::removePropertiesChangeListener ( const css::uno::Sequence< OUString > &  PropertyNames,
const css::uno::Reference< css::beans::XPropertiesChangeListener > &  Listener 
)
overridevirtual

Definition at line 363 of file bc.cxx.

References m_aMutex, and m_pPropertyListener.

◆ removeProperty()

void SAL_CALL BaseContent::removeProperty ( const OUString &  Name)
overridevirtual

Definition at line 473 of file bc.cxx.

References fileaccess::TaskManager::deassociate(), Deleted, m_aUncPath, m_nState, m_pMyShell, and Name.

◆ removePropertySetInfoChangeListener()

void SAL_CALL BaseContent::removePropertySetInfoChangeListener ( const css::uno::Reference< css::beans::XPropertySetInfoChangeListener > &  Listener)
overridevirtual

◆ setParent()

void SAL_CALL BaseContent::setParent ( const css::uno::Reference< css::uno::XInterface > &  Parent)
overridevirtual

Definition at line 596 of file bc.cxx.

References THROW_WHERE.

◆ setPropertyValues()

Sequence< Any > BaseContent::setPropertyValues ( sal_Int32  nMyCommandIdentifier,
const css::uno::Sequence< css::beans::PropertyValue > &  Values 
)
private

◆ supportsService()

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

Definition at line 198 of file bc.cxx.

References ServiceName, and cppu::supportsService().

◆ transfer()

void BaseContent::transfer ( sal_Int32  nMyCommandIdentifier,
const css::ucb::TransferInfo &  aTransferInfo 
)
private

Friends And Related Function Documentation

◆ ContentEventNotifier

friend class ContentEventNotifier
friend

Definition at line 252 of file bc.hxx.

Referenced by cCEL(), cDEL(), and cEXC().

Member Data Documentation

◆ m_aContentEventListeners

comphelper::OInterfaceContainerHelper4<css::ucb::XContentEventListener> fileaccess::BaseContent::m_aContentEventListeners
private

Definition at line 208 of file bc.hxx.

Referenced by addContentEventListener(), cCEL(), cDEL(), cEXC(), dispose(), and removeContentEventListener().

◆ m_aDisposeEventListeners

comphelper::OInterfaceContainerHelper4<css::lang::XEventListener> fileaccess::BaseContent::m_aDisposeEventListeners
private

Definition at line 207 of file bc.hxx.

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

◆ m_aMutex

std::mutex fileaccess::BaseContent::m_aMutex
private

◆ m_aPropertySetInfoChangeListeners

comphelper::OInterfaceContainerHelper4<css::beans::XPropertySetInfoChangeListener> fileaccess::BaseContent::m_aPropertySetInfoChangeListeners
private

◆ m_aUncPath

OUString fileaccess::BaseContent::m_aUncPath
private

◆ m_bFolder

bool fileaccess::BaseContent::m_bFolder
private

Definition at line 203 of file bc.hxx.

Referenced by getContentType(), and getPropertyValues().

◆ m_nState

sal_uInt16 fileaccess::BaseContent::m_nState
private

◆ m_pMyShell

TaskManager* fileaccess::BaseContent::m_pMyShell
private

◆ m_pPropertyListener

std::unique_ptr<PropertyListeners> fileaccess::BaseContent::m_pPropertyListener
private

Definition at line 210 of file bc.hxx.

Referenced by addPropertiesChangeListener(), cPCL(), dispose(), and removePropertiesChangeListener().

◆ m_xContentIdentifier

css::uno::Reference< css::ucb::XContentIdentifier > fileaccess::BaseContent::m_xContentIdentifier
private

Definition at line 196 of file bc.hxx.

Referenced by cCEL(), cDEL(), cEXC(), getIdentifier(), and insert().


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