LibreOffice Module ucb (master) 1
|
#include <gio_content.hxx>
Public Member Functions | |
Content (const css::uno::Reference< css::uno::XComponentContext > &rxContext, ContentProvider *pProvider, const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier) | |
Content (const css::uno::Reference< css::uno::XComponentContext > &rxContext, ContentProvider *pProvider, const css::uno::Reference< css::ucb::XContentIdentifier > &Identifier, bool bIsFolder) | |
virtual | ~Content () override |
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 |
virtual css::uno::Any SAL_CALL | queryInterface (const css::uno::Type &rType) override |
virtual void SAL_CALL | acquire () noexcept override |
virtual void SAL_CALL | release () noexcept override |
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::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 |
css::uno::Sequence< css::ucb::ContentInfo > | queryCreatableContentsInfo (const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv) |
GFile * | getGFile () |
Public Member Functions inherited from ucbhelper::ContentImplHelper | |
ContentImplHelper (css::uno::Reference< css::uno::XComponentContext > xContext, rtl::Reference< ContentProviderImplHelper > xProvider, css::uno::Reference< css::ucb::XContentIdentifier > Identifier) | |
virtual | ~ContentImplHelper () override |
virtual css::uno::Any SAL_CALL | queryInterface (const css::uno::Type &rType) override |
virtual void SAL_CALL | acquire () noexcept override |
virtual void SAL_CALL | release () noexcept override |
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=0 |
virtual sal_Bool SAL_CALL | supportsService (const OUString &ServiceName) override |
virtual css::uno::Sequence< OUString > SAL_CALL | getSupportedServiceNames () override=0 |
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 css::uno::Reference< css::ucb::XContentIdentifier > SAL_CALL | getIdentifier () override |
virtual OUString SAL_CALL | getContentType () override=0 |
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 css::uno::Any SAL_CALL | execute (const css::ucb::Command &aCommand, sal_Int32 CommandId, const css::uno::Reference< css::ucb::XCommandEnvironment > &Environment) override=0 |
virtual void SAL_CALL | abort (sal_Int32 CommandId) override=0 |
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 |
Private Types | |
typedef rtl::Reference< Content > | ContentRef |
typedef std::vector< ContentRef > | ContentRefList |
Private Member Functions | |
GFileInfo * | getGFileInfo (const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv, GError **ppError=nullptr) |
bool | isFolder (const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv) |
css::uno::Any | mapGIOError (GError *error) |
css::uno::Any | getBadArgExcept () |
css::uno::Reference< css::sdbc::XRow > | getPropertyValues (const css::uno::Sequence< css::beans::Property > &rProperties, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv) |
void | queryChildren (ContentRefList &rChildren) |
bool | doSetFileInfo (GFileInfo *pNewInfo) |
css::uno::Any | open (const css::ucb::OpenCommandArgument2 &rArg, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv) |
void | transfer (const css::ucb::TransferInfo &rTransferInfo, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv) |
void | insert (const css::uno::Reference< css::io::XInputStream > &xInputStream, bool bReplaceExisting, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv) |
void | destroy (bool bDeletePhysical) |
css::uno::Sequence< css::uno::Any > | setPropertyValues (const css::uno::Sequence< css::beans::PropertyValue > &rValues, const css::uno::Reference< css::ucb::XCommandEnvironment > &xEnv) |
bool | feedSink (const css::uno::Reference< css::uno::XInterface > &aSink) |
bool | exchangeIdentity (const css::uno::Reference< css::ucb::XContentIdentifier > &xNewId) |
void | getFileInfo (css::uno::Reference< css::ucb::XCommandEnvironment > const &env, GFileInfo **info, bool fail) |
Static Private Member Functions | |
static void | copyData (const css::uno::Reference< css::io::XInputStream > &xIn, const css::uno::Reference< css::io::XOutputStream > &xOut) |
Private Attributes | |
ContentProvider * | m_pProvider |
GFile * | mpFile |
GFileInfo * | mpInfo |
bool | mbTransient |
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< ContentProviderImplHelper > | m_xProvider |
sal_uInt32 | m_nCommandId |
Definition at line 63 of file gio_content.hxx.
|
private |
Definition at line 83 of file gio_content.hxx.
|
private |
Definition at line 84 of file gio_content.hxx.
gio::Content::Content | ( | const css::uno::Reference< css::uno::XComponentContext > & | rxContext, |
ContentProvider * | pProvider, | ||
const css::uno::Reference< css::ucb::XContentIdentifier > & | Identifier | ||
) |
css::ucb::ContentCreationException |
Definition at line 75 of file gio_content.cxx.
References Identifier, ucbhelper::ContentImplHelper::m_xIdentifier, and SAL_INFO.
gio::Content::Content | ( | const css::uno::Reference< css::uno::XComponentContext > & | rxContext, |
ContentProvider * | pProvider, | ||
const css::uno::Reference< css::ucb::XContentIdentifier > & | Identifier, | ||
bool | bIsFolder | ||
) |
css::ucb::ContentCreationException |
Definition at line 85 of file gio_content.cxx.
References Identifier, ucbhelper::ContentImplHelper::m_xIdentifier, mpInfo, and SAL_INFO.
|
overridevirtual |
Definition at line 98 of file gio_content.cxx.
|
overridevirtual |
Implements ucbhelper::ContentImplHelper.
Definition at line 117 of file gio_content.cxx.
|
overridevirtualnoexcept |
Reimplemented from ucbhelper::ContentImplHelper.
Definition at line 1318 of file gio_content.cxx.
|
staticprivate |
Definition at line 831 of file gio_content.cxx.
References gio::TRANSFER_BUFFER_SIZE.
Referenced by feedSink(), and insert().
|
overridevirtual |
Definition at line 1156 of file gio_content.cxx.
References aURL, gio::GIO_FILE_TYPE, gio::GIO_FOLDER_TYPE, Info, m_pProvider, ucbhelper::ContentImplHelper::m_xContext, ucbhelper::ContentImplHelper::m_xIdentifier, name, SAL_INFO, and SAL_WARN.
Referenced by execute().
|
private |
css::uno::Exception |
Definition at line 1026 of file gio_content.cxx.
References ucbhelper::ContentImplHelper::deleted(), and queryChildren().
Referenced by execute().
|
private |
Definition at line 818 of file gio_content.cxx.
References getGFile(), and mbTransient.
Referenced by setPropertyValues().
|
private |
Definition at line 597 of file gio_content.cxx.
References ucbhelper::ContentImplHelper::exchange(), ucbhelper::ContentImplHelper::m_xIdentifier, mbTransient, and queryChildren().
Referenced by setPropertyValues().
|
overridevirtual |
Implements ucbhelper::ContentImplHelper.
Definition at line 938 of file gio_content.cxx.
References aCommand, aProperties, ucbhelper::cancelCommandExecution(), createNewContent(), destroy(), getBadArgExcept(), ucbhelper::ContentImplHelper::getCommandInfo(), getGFile(), ucbhelper::ContentImplHelper::getPropertySetInfo(), getPropertyValues(), insert(), isFolder(), mapGIOError(), open(), Properties, SAL_INFO, SAL_WARN, setPropertyValues(), and transfer().
|
private |
Definition at line 844 of file gio_content.cxx.
References gio::convertToException(), copyData(), getGFile(), ucbhelper::ContentImplHelper::m_xContext, and xSink.
Referenced by open().
|
private |
Definition at line 302 of file gio_content.cxx.
Referenced by execute(), mapGIOError(), and setPropertyValues().
|
overridevirtual |
Implements ucbhelper::ContentImplHelper.
Definition at line 1274 of file gio_content.cxx.
References isFolder(), and SAL_N_ELEMENTS.
|
overridevirtual |
Implements ucbhelper::ContentImplHelper.
Definition at line 124 of file gio_content.cxx.
References gio::GIO_FILE_TYPE, gio::GIO_FOLDER_TYPE, and isFolder().
|
private |
Definition at line 641 of file gio_content.cxx.
References ucbhelper::cancelCommandExecution(), env, err, fail, getGFileInfo(), mapGIOError(), and mbTransient.
Referenced by getPropertyValues().
GFile * gio::Content::getGFile | ( | ) |
Definition at line 408 of file gio_content.cxx.
References ucbhelper::ContentImplHelper::m_xIdentifier, mpFile, and OUStringToOString().
Referenced by doSetFileInfo(), execute(), feedSink(), getGFileInfo(), getParentURL(), insert(), open(), and transfer().
|
private |
Definition at line 371 of file gio_content.cxx.
References err, getGFile(), ucbhelper::ContentImplHelper::m_xIdentifier, mbTransient, mpInfo, SAL_INFO, and SAL_WARN.
Referenced by getFileInfo(), insert(), isFolder(), and setPropertyValues().
|
overridevirtual |
Reimplemented from ucbhelper::ContentImplHelper.
|
overridevirtual |
Implements ucbhelper::ContentImplHelper.
Definition at line 1334 of file gio_content.cxx.
|
overridevirtual |
Implements ucbhelper::ContentImplHelper.
Definition at line 104 of file gio_content.cxx.
References getGFile().
Referenced by setPropertyValues().
|
overridevirtual |
Implements ucbhelper::ContentImplHelper.
Definition at line 1227 of file gio_content.cxx.
References SAL_N_ELEMENTS.
|
private |
Definition at line 437 of file gio_content.cxx.
References gio::getDateFromUnix(), getFileInfo(), ucbhelper::ContentImplHelper::m_xContext, pName, queryCreatableContentsInfo(), and SAL_WARN.
Referenced by execute().
|
overridevirtual |
Implements ucbhelper::ContentImplHelper.
Definition at line 1339 of file gio_content.cxx.
|
overridevirtual |
Reimplemented from ucbhelper::ContentImplHelper.
Definition at line 1191 of file gio_content.cxx.
References CPPU_TYPE_REF, cppu::OTypeCollection::getTypes(), and isFolder().
|
private |
css::uno::Exception |
Definition at line 1041 of file gio_content.cxx.
References ucbhelper::cancelCommandExecution(), copyData(), getGFile(), getGFileInfo(), ucbhelper::ContentImplHelper::inserted(), mapGIOError(), mbTransient, and SAL_INFO.
Referenced by execute().
|
private |
Definition at line 415 of file gio_content.cxx.
References getGFileInfo().
Referenced by execute(), getCommands(), getContentType(), getTypes(), open(), and queryCreatableContentsInfo().
|
private |
Definition at line 294 of file gio_content.cxx.
References gio::convertToException(), and getBadArgExcept().
Referenced by execute(), getFileInfo(), insert(), setPropertyValues(), and transfer().
|
private |
css::uno::Exception |
Definition at line 873 of file gio_content.cxx.
References ucbhelper::cancelCommandExecution(), feedSink(), getGFile(), isFolder(), ucbhelper::ContentImplHelper::m_xContext, ucbhelper::ContentImplHelper::m_xIdentifier, SAL_INFO, and SAL_WARN.
Referenced by execute().
|
private |
Definition at line 561 of file gio_content.cxx.
References aURL, ucbhelper::ContentImplHelper::m_xIdentifier, ucbhelper::ContentImplHelper::m_xProvider, and nPos.
Referenced by destroy(), and exchangeIdentity().
|
overridevirtual |
Definition at line 1150 of file gio_content.cxx.
References queryCreatableContentsInfo().
Referenced by getPropertyValues(), and queryCreatableContentsInfo().
css::uno::Sequence< css::ucb::ContentInfo > gio::Content::queryCreatableContentsInfo | ( | const css::uno::Reference< css::ucb::XCommandEnvironment > & | xEnv | ) |
css::uno::RuntimeException |
Definition at line 1126 of file gio_content.cxx.
References cppu::UnoType< typename T >::get(), gio::GIO_FILE_TYPE, gio::GIO_FOLDER_TYPE, isFolder(), and props.
|
overridevirtual |
Reimplemented from ucbhelper::ContentImplHelper.
Definition at line 1328 of file gio_content.cxx.
References cppu::queryInterface().
|
overridevirtualnoexcept |
Reimplemented from ucbhelper::ContentImplHelper.
Definition at line 1323 of file gio_content.cxx.
|
private |
Definition at line 660 of file gio_content.cxx.
References aEvent, ucbhelper::cancelCommandExecution(), doSetFileInfo(), exchangeIdentity(), getBadArgExcept(), getGFileInfo(), getParentURL(), gio::getReadOnlyException(), i, mapGIOError(), mbTransient, mpFile, mpInfo, n, nCount, fileaccess::newName(), ucbhelper::ContentImplHelper::notifyPropertiesChange(), OUStringToOString(), pValues, SAL_INFO, and SAL_WARN.
Referenced by execute().
|
private |
css::uno::Exception |
Definition at line 1090 of file gio_content.cxx.
References ucbhelper::cancelCommandExecution(), gio::DEFAULT_COPYDATA_FLAGS, getGFile(), ucbhelper::ContentImplHelper::m_xIdentifier, mapGIOError(), OUStringToOString(), and SAL_INFO.
Referenced by execute().
|
private |
Definition at line 66 of file gio_content.hxx.
Referenced by createNewContent().
|
private |
Definition at line 69 of file gio_content.hxx.
Referenced by doSetFileInfo(), exchangeIdentity(), getFileInfo(), getGFileInfo(), insert(), and setPropertyValues().
|
private |
Definition at line 67 of file gio_content.hxx.
Referenced by getGFile(), setPropertyValues(), and ~Content().
|
private |
Definition at line 68 of file gio_content.hxx.
Referenced by Content(), getGFileInfo(), setPropertyValues(), and ~Content().