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

#include <hierarchycontent.hxx>

Inheritance diagram for hierarchy_ucp::HierarchyContent:
[legend]
Collaboration diagram for hierarchy_ucp::HierarchyContent:
[legend]

Public Member Functions

virtual ~HierarchyContent () override
 
virtual css::uno::Any SAL_CALL queryInterface (const css::uno::Type &rType) override
 
virtual void SAL_CALL acquire () override throw ()
 
virtual void SAL_CALL release () override throw ()
 
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId () override
 
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes () override
 
virtual OUString SAL_CALL getImplementationName () override
 
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames () override
 
virtual OUString SAL_CALL getContentType () override
 
virtual css::uno::Reference< css::ucb::XContentIdentifier > SAL_CALL getIdentifier () 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::Sequence< css::ucb::ContentInfo > SAL_CALL queryCreatableContentsInfo () override
 
virtual css::uno::Reference< css::ucb::XContent > SAL_CALL createNewContent (const css::ucb::ContentInfo &Info) override
 
- Public Member Functions inherited from ucbhelper::ContentImplHelper
 ContentImplHelper (const css::uno::Reference< css::uno::XComponentContext > &rxContext, const rtl::Reference< ContentProviderImplHelper > &rxProvider, const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier)
 
virtual ~ContentImplHelper () override
 
virtual sal_Bool SAL_CALL supportsService (const OUString &ServiceName) 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 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 sal_Int32 SAL_CALL createCommandIdentifier () 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 addCommandInfoChangeListener (const css::uno::Reference< css::ucb::XCommandInfoChangeListener > &Listener) override
 
virtual void SAL_CALL removeCommandInfoChangeListener (const css::uno::Reference< css::ucb::XCommandInfoChangeListener > &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::Reference< css::uno::XInterface > SAL_CALL getParent () override
 
virtual void SAL_CALL setParent (const css::uno::Reference< css::uno::XInterface > &Parent) override
 
const rtl::Reference< ContentProviderImplHelper > & getProvider () const
 

Static Public Member Functions

static HierarchyContentcreate (const css::uno::Reference< css::uno::XComponentContext > &rxContext, HierarchyContentProvider *pProvider, const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier)
 
static HierarchyContentcreate (const css::uno::Reference< css::uno::XComponentContext > &rxContext, HierarchyContentProvider *pProvider, const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier, const css::ucb::ContentInfo &Info)
 
static css::uno::Reference< css::sdbc::XRow > getPropertyValues (const css::uno::Reference< css::uno::XComponentContext > &rxContext, const css::uno::Sequence< css::beans::Property > &rProperties, const HierarchyContentProperties &rData, HierarchyContentProvider *pProvider, const OUString &rContentId)
 

Private Types

enum  ContentKind {
  LINK,
  FOLDER,
  ROOT
}
 
enum  ContentState {
  TRANSIENT,
  PERSISTENT,
  DEAD
}
 
typedef rtl::Reference< HierarchyContentHierarchyContentRef
 
typedef std::vector< HierarchyContentRefHierarchyContentRefVector
 

Private Member Functions

 HierarchyContent (const css::uno::Reference< css::uno::XComponentContext > &rxContext, HierarchyContentProvider *pProvider, const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier, const HierarchyContentProperties &rProps)
 
 HierarchyContent (const css::uno::Reference< css::uno::XComponentContext > &rxContext, HierarchyContentProvider *pProvider, const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier, const css::ucb::ContentInfo &Info)
 
virtual css::uno::Sequence< css::beans::Property > getProperties (const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv) override
 
virtual css::uno::Sequence< css::ucb::CommandInfo > getCommands (const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv) override
 
virtual OUString getParentURL () override
 
bool hasData (const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier)
 
bool storeData ()
 
void renameData (const css::uno::Reference< css::ucb::XContentIdentifier > &xOldId, const css::uno::Reference< css::ucb::XContentIdentifier > &xNewId)
 
bool removeData ()
 
void setKind (const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier)
 
bool isReadOnly ()
 
bool isFolder () const
 
css::uno::Reference< css::ucb::XContentIdentifier > makeNewIdentifier (const OUString &rTitle)
 
void queryChildren (HierarchyContentRefVector &rChildren)
 
bool exchangeIdentity (const css::uno::Reference< css::ucb::XContentIdentifier > &xNewId)
 
css::uno::Reference< css::sdbc::XRow > getPropertyValues (const css::uno::Sequence< css::beans::Property > &rProperties)
 
css::uno::Sequence< css::uno::Any > setPropertyValues (const css::uno::Sequence< css::beans::PropertyValue > &rValues, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv)
 
void insert (sal_Int32 nNameClashResolve, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv)
 
void destroy (bool bDeletePhysical, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv)
 
void transfer (const css::ucb::TransferInfo &rInfo, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv)
 

Static Private Member Functions

static bool hasData (const css::uno::Reference< css::uno::XComponentContext > &rxContext, HierarchyContentProvider *pProvider, const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier)
 
static bool loadData (const css::uno::Reference< css::uno::XComponentContext > &rxContext, HierarchyContentProvider *pProvider, const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier, HierarchyContentProperties &rProps)
 

Private Attributes

HierarchyContentProperties m_aProps
 
ContentKind m_eKind
 
ContentState m_eState
 
HierarchyContentProviderm_pProvider
 
bool m_bCheckedReadOnly
 
bool m_bIsReadOnly
 

Additional Inherited Members

- Protected Member Functions inherited from ucbhelper::ContentImplHelper
css::uno::Reference< css::beans::XPropertySetInfo > getPropertySetInfo (const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv, bool bCache=true)
 
css::uno::Reference< css::ucb::XCommandInfo > getCommandInfo (const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv, bool bCache=true)
 
void notifyPropertiesChange (const css::uno::Sequence< css::beans::PropertyChangeEvent > &evt) const
 
void notifyPropertySetInfoChange (const css::beans::PropertySetInfoChangeEvent &evt) const
 
void notifyContentEvent (const css::ucb::ContentEvent &evt) const
 
void inserted ()
 
void deleted ()
 
bool exchange (const css::uno::Reference< css::ucb::XContentIdentifier > &rNewId)
 
css::uno::Reference< css::ucb::XPersistentPropertySet > getAdditionalPropertySet (bool bCreate)
 
bool renameAdditionalPropertySet (const OUString &rOldKey, const OUString &rNewKey)
 
bool copyAdditionalPropertySet (const OUString &rSourceKey, const OUString &rTargetKey)
 
bool removeAdditionalPropertySet ()
 
- Protected Attributes inherited from ucbhelper::ContentImplHelper
osl::Mutex m_aMutex
 
css::uno::Reference< css::uno::XComponentContext > m_xContext
 
css::uno::Reference< css::ucb::XContentIdentifier > m_xIdentifier
 
rtl::Reference< ContentProviderImplHelperm_xProvider
 
sal_uInt32 m_nCommandId
 

Detailed Description

Definition at line 96 of file hierarchycontent.hxx.

Member Typedef Documentation

Definition at line 157 of file hierarchycontent.hxx.

Definition at line 158 of file hierarchycontent.hxx.

Member Enumeration Documentation

Enumerator
LINK 
FOLDER 
ROOT 

Definition at line 99 of file hierarchycontent.hxx.

Enumerator
TRANSIENT 
PERSISTENT 
DEAD 

Definition at line 100 of file hierarchycontent.hxx.

Constructor & Destructor Documentation

hierarchy_ucp::HierarchyContent::HierarchyContent ( const css::uno::Reference< css::uno::XComponentContext > &  rxContext,
HierarchyContentProvider pProvider,
const css::uno::Reference< css::ucb::XContentIdentifier > &  Identifier,
const HierarchyContentProperties rProps 
)
private
hierarchy_ucp::HierarchyContent::HierarchyContent ( const css::uno::Reference< css::uno::XComponentContext > &  rxContext,
HierarchyContentProvider pProvider,
const css::uno::Reference< css::ucb::XContentIdentifier > &  Identifier,
const css::ucb::ContentInfo &  Info 
)
private
HierarchyContent::~HierarchyContent ( )
overridevirtual

Definition at line 150 of file hierarchycontent.cxx.

Member Function Documentation

void SAL_CALL HierarchyContent::abort ( sal_Int32  CommandId)
overridevirtual

Implements ucbhelper::ContentImplHelper.

Definition at line 511 of file hierarchycontent.cxx.

void SAL_CALL HierarchyContent::acquire ( )
throw (
)
overridevirtual

Reimplemented from ucbhelper::ContentImplHelper.

Definition at line 159 of file hierarchycontent.cxx.

static HierarchyContent* hierarchy_ucp::HierarchyContent::create ( const css::uno::Reference< css::uno::XComponentContext > &  rxContext,
HierarchyContentProvider pProvider,
const css::uno::Reference< css::ucb::XContentIdentifier > &  Identifier 
)
static
static HierarchyContent* hierarchy_ucp::HierarchyContent::create ( const css::uno::Reference< css::uno::XComponentContext > &  rxContext,
HierarchyContentProvider pProvider,
const css::uno::Reference< css::ucb::XContentIdentifier > &  Identifier,
const css::ucb::ContentInfo &  Info 
)
static
uno::Reference< ucb::XContent > SAL_CALL HierarchyContent::createNewContent ( const css::ucb::ContentInfo &  Info)
overridevirtual
void HierarchyContent::destroy ( bool  bDeletePhysical,
const css::uno::Reference< css::ucb::XCommandEnvironment > &  xEnv 
)
private
Exceptions
css::uno::Exception

Definition at line 1442 of file hierarchycontent.cxx.

References ucbhelper::cancelCommandExecution(), tdoc_ucp::FOLDER, and m_aMutex.

bool HierarchyContent::exchangeIdentity ( const css::uno::Reference< css::ucb::XContentIdentifier > &  xNewId)
private

Definition at line 768 of file hierarchycontent.cxx.

References tdoc_ucp::FOLDER, and m_aMutex.

uno::Any SAL_CALL HierarchyContent::execute ( const css::ucb::Command &  aCommand,
sal_Int32  CommandId,
const css::uno::Reference< css::ucb::XCommandEnvironment > &  Environment 
)
overridevirtual
uno::Sequence< ucb::CommandInfo > HierarchyContent::getCommands ( const css::uno::Reference< css::ucb::XCommandEnvironment > &  xEnv)
overrideprivatevirtual

Implements ucbhelper::ContentImplHelper.

Definition at line 374 of file hierarchycontentcaps.cxx.

References tdoc_ucp::FOLDER, LINK, m_aMutex, and MAKECMDSEQUENCE.

OUString SAL_CALL HierarchyContent::getContentType ( )
overridevirtual

Implements ucbhelper::ContentImplHelper.

Definition at line 273 of file hierarchycontent.cxx.

uno::Reference< ucb::XContentIdentifier > SAL_CALL HierarchyContent::getIdentifier ( )
overridevirtual

Reimplemented from ucbhelper::ContentImplHelper.

Definition at line 281 of file hierarchycontent.cxx.

References TRANSIENT.

virtual css::uno::Sequence< sal_Int8 > SAL_CALL hierarchy_ucp::HierarchyContent::getImplementationId ( )
overridevirtual

Reimplemented from ucbhelper::ContentImplHelper.

OUString SAL_CALL HierarchyContent::getImplementationName ( )
overridevirtual

Implements ucbhelper::ContentImplHelper.

Definition at line 246 of file hierarchycontent.cxx.

OUString HierarchyContent::getParentURL ( )
overrideprivatevirtual
uno::Sequence< beans::Property > HierarchyContent::getProperties ( const css::uno::Reference< css::ucb::XCommandEnvironment > &  xEnv)
overrideprivatevirtual

Implements ucbhelper::ContentImplHelper.

Definition at line 80 of file hierarchycontentcaps.cxx.

References tdoc_ucp::FOLDER, LINK, m_aMutex, and MAKEPROPSEQUENCE.

css::uno::Reference< css::sdbc::XRow > hierarchy_ucp::HierarchyContent::getPropertyValues ( const css::uno::Sequence< css::beans::Property > &  rProperties)
private
static css::uno::Reference< css::sdbc::XRow > hierarchy_ucp::HierarchyContent::getPropertyValues ( const css::uno::Reference< css::uno::XComponentContext > &  rxContext,
const css::uno::Sequence< css::beans::Property > &  rProperties,
const HierarchyContentProperties rData,
HierarchyContentProvider pProvider,
const OUString &  rContentId 
)
static
uno::Sequence< OUString > SAL_CALL HierarchyContent::getSupportedServiceNames ( )
overridevirtual

Implements ucbhelper::ContentImplHelper.

Definition at line 254 of file hierarchycontent.cxx.

References tdoc_ucp::FOLDER, and LINK.

uno::Sequence< uno::Type > SAL_CALL HierarchyContent::getTypes ( )
overridevirtual

Reimplemented from ucbhelper::ContentImplHelper.

Definition at line 203 of file hierarchycontent.cxx.

References CPPU_TYPE_REF, and cppu::OTypeCollection::getTypes().

static bool hierarchy_ucp::HierarchyContent::hasData ( const css::uno::Reference< css::uno::XComponentContext > &  rxContext,
HierarchyContentProvider pProvider,
const css::uno::Reference< css::ucb::XContentIdentifier > &  Identifier 
)
staticprivate

Referenced by hasData().

bool hierarchy_ucp::HierarchyContent::hasData ( const css::uno::Reference< css::ucb::XContentIdentifier > &  Identifier)
inlineprivate

Definition at line 135 of file hierarchycontent.hxx.

References hasData(), and ucbhelper::ContentImplHelper::m_xContext.

void HierarchyContent::insert ( sal_Int32  nNameClashResolve,
const css::uno::Reference< css::ucb::XCommandEnvironment > &  xEnv 
)
private
Exceptions
css::uno::Exception

Definition at line 1300 of file hierarchycontent.cxx.

References ucbhelper::cancelCommandExecution(), comphelper::InitAnyPropertySequence(), inserted(), and m_aMutex.

bool hierarchy_ucp::HierarchyContent::isFolder ( ) const
inlineprivate

Definition at line 152 of file hierarchycontent.hxx.

References LINK.

bool HierarchyContent::isReadOnly ( )
private

Definition at line 671 of file hierarchycontent.cxx.

References m_aMutex.

bool HierarchyContent::loadData ( const css::uno::Reference< css::uno::XComponentContext > &  rxContext,
HierarchyContentProvider pProvider,
const css::uno::Reference< css::ucb::XContentIdentifier > &  Identifier,
HierarchyContentProperties rProps 
)
staticprivate
uno::Reference< ucb::XContentIdentifier > HierarchyContent::makeNewIdentifier ( const OUString &  rTitle)
private
void HierarchyContent::queryChildren ( HierarchyContentRefVector rChildren)
private

Definition at line 721 of file hierarchycontent.cxx.

References tdoc_ucp::FOLDER, and nPos.

uno::Sequence< ucb::ContentInfo > SAL_CALL HierarchyContent::queryCreatableContentsInfo ( )
overridevirtual

Definition at line 522 of file hierarchycontent.cxx.

uno::Any SAL_CALL HierarchyContent::queryInterface ( const css::uno::Type &  rType)
overridevirtual

Reimplemented from ucbhelper::ContentImplHelper.

Definition at line 175 of file hierarchycontent.cxx.

References uno::Any::hasValue(), and cppu::queryInterface().

void SAL_CALL HierarchyContent::release ( )
throw (
)
overridevirtual

Reimplemented from ucbhelper::ContentImplHelper.

Definition at line 167 of file hierarchycontent.cxx.

bool HierarchyContent::removeData ( )
private

Definition at line 646 of file hierarchycontent.cxx.

References m_xContext, and hierarchy_ucp::HierarchyEntry::remove().

void HierarchyContent::renameData ( const css::uno::Reference< css::ucb::XContentIdentifier > &  xOldId,
const css::uno::Reference< css::ucb::XContentIdentifier > &  xNewId 
)
private

Definition at line 635 of file hierarchycontent.cxx.

References m_xContext, and hierarchy_ucp::HierarchyEntry::move().

void HierarchyContent::setKind ( const css::uno::Reference< css::ucb::XContentIdentifier > &  Identifier)
private

Definition at line 654 of file hierarchycontent.cxx.

References tdoc_ucp::FOLDER, and LINK.

uno::Sequence< uno::Any > HierarchyContent::setPropertyValues ( const css::uno::Sequence< css::beans::PropertyValue > &  rValues,
const css::uno::Reference< css::ucb::XCommandEnvironment > &  xEnv 
)
private
bool HierarchyContent::storeData ( )
private

Definition at line 627 of file hierarchycontent.cxx.

References m_xContext, and hierarchy_ucp::HierarchyEntry::setData().

void HierarchyContent::transfer ( const css::ucb::TransferInfo &  rInfo,
const css::uno::Reference< css::ucb::XCommandEnvironment > &  xEnv 
)
private

Member Data Documentation

HierarchyContentProperties hierarchy_ucp::HierarchyContent::m_aProps
private

Definition at line 106 of file hierarchycontent.hxx.

bool hierarchy_ucp::HierarchyContent::m_bCheckedReadOnly
private

Definition at line 110 of file hierarchycontent.hxx.

bool hierarchy_ucp::HierarchyContent::m_bIsReadOnly
private

Definition at line 111 of file hierarchycontent.hxx.

ContentKind hierarchy_ucp::HierarchyContent::m_eKind
private

Definition at line 107 of file hierarchycontent.hxx.

ContentState hierarchy_ucp::HierarchyContent::m_eState
private

Definition at line 108 of file hierarchycontent.hxx.

HierarchyContentProvider* hierarchy_ucp::HierarchyContent::m_pProvider
private

Definition at line 109 of file hierarchycontent.hxx.


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