LibreOffice Module fpicker (master) 1
|
#include <contentenumeration.hxx>
Public Types | |
typedef ::std::vector< std::unique_ptr< SortingData_Impl > > | ContentData |
Public Member Functions | |
FileViewContentEnumerator (const css::uno::Reference< css::ucb::XCommandEnvironment > &_rxCommandEnv, ContentData &_rContentToFill, ::osl::Mutex &_rContentMutex) | |
constructs an enumerator instance More... | |
void | enumerateFolderContent (const FolderDescriptor &_rFolder, IEnumerationResultHandler *_pResultHandler) |
enumerates the content of a given folder More... | |
EnumerationResult | enumerateFolderContentSync (const FolderDescriptor &_rFolder, const css::uno::Sequence< OUString > &rDenyList) |
enumerates the content of a given folder synchronously More... | |
void | cancel () |
cancels the running operation. More... | |
Public Member Functions inherited from salhelper::Thread | |
Thread (char const *name) | |
void | launch () |
Public Member Functions inherited from salhelper::SimpleReferenceObject | |
SimpleReferenceObject () | |
void | acquire () |
void | release () |
Protected Member Functions | |
virtual | ~FileViewContentEnumerator () override |
Protected Member Functions inherited from salhelper::Thread | |
virtual | ~Thread () SAL_OVERRIDE |
virtual void | execute ()=0 |
Protected Member Functions inherited from salhelper::SimpleReferenceObject | |
virtual | ~SimpleReferenceObject () COVERITY_NOEXCEPT_FALSE |
Private Member Functions | |
bool | URLOnDenyList (std::u16string_view sRealURL) |
EnumerationResult | enumerateFolderContent () |
virtual void | execute () override |
Private Attributes | |
ContentData & | m_rContent |
::osl::Mutex & | m_rContentMutex |
std::mutex | m_aMutex |
FolderDescriptor | m_aFolder |
css::uno::Reference< css::ucb::XCommandEnvironment > | m_xCommandEnv |
IEnumerationResultHandler * | m_pResultHandler |
bool | m_bCancelled |
css::uno::Sequence< OUString > | m_rDenyList |
Additional Inherited Members | |
Static Public Member Functions inherited from salhelper::Thread | |
static void * | operator new (std::size_t size) |
static void | operator delete (void *pointer) |
Static Public Member Functions inherited from salhelper::SimpleReferenceObject | |
static void * | operator new (std::size_t nSize) |
static void * | operator new (std::size_t nSize, std::nothrow_t const &rNothrow) |
static void | operator delete (void *pPtr) |
static void | operator delete (void *pPtr, std::nothrow_t const &rNothrow) |
Protected Attributes inherited from salhelper::SimpleReferenceObject | |
oslInterlockedCount | m_nCount |
Definition at line 158 of file contentenumeration.hxx.
typedef ::std::vector< std::unique_ptr<SortingData_Impl> > svt::FileViewContentEnumerator::ContentData |
Definition at line 161 of file contentenumeration.hxx.
svt::FileViewContentEnumerator::FileViewContentEnumerator | ( | const css::uno::Reference< css::ucb::XCommandEnvironment > & | _rxCommandEnv, |
ContentData & | _rContentToFill, | ||
::osl::Mutex & | _rContentMutex | ||
) |
constructs an enumerator instance
_rContentToFill | the structure which is to be filled with the found content |
_rContentMutex | the mutex which protects the access to <arg>_rContentToFill</arg> |
_pTranslator | an instance which should be used to translate content titles. May be <NULL> |
Definition at line 72 of file contentenumeration.cxx.
References m_rContent.
|
overrideprotectedvirtual |
Definition at line 85 of file contentenumeration.cxx.
void svt::FileViewContentEnumerator::cancel | ( | ) |
cancels the running operation.
Note that "cancel" may mean that the operation is running, but its result is simply disregarded later on.
Definition at line 90 of file contentenumeration.cxx.
References svt::FolderDescriptor::aContent, m_aFolder, m_aMutex, m_bCancelled, m_pResultHandler, and svt::FolderDescriptor::sURL.
|
private |
Definition at line 132 of file contentenumeration.cxx.
References svt::FolderDescriptor::aContent, aTargetURL, ucbhelper::Content::createDynamicCursor(), svt::IEnumerationResultHandler::enumerationDone(), svt::ERROR, Exception, ucbhelper::Content::get(), SvFileInformationManager::GetFileDescription(), SvFileInformationManager::GetFolderDescription(), comphelper::getProcessComponentContext(), ucbhelper::Content::getPropertyValue(), INCLUDE_FOLDERS_AND_DOCUMENTS, m_aFolder, m_aMutex, m_bCancelled, m_pResultHandler, m_rContent, m_rContentMutex, m_xCommandEnv, pData, ROW_DATE_CREATE, ROW_DATE_MOD, ROW_IS_COMPACTDISC, ROW_IS_FLOPPY, ROW_IS_FOLDER, ROW_IS_HIDDEN, ROW_IS_REMOTE, ROW_IS_REMOVABLE, ROW_IS_VOLUME, ROW_SIZE, ROW_TARGET_URL, ROW_TITLE, svt::SUCCESS, svt::FolderDescriptor::sURL, TOOLS_WARN_EXCEPTION, and URLOnDenyList().
Referenced by enumerateFolderContentSync(), and execute().
void svt::FileViewContentEnumerator::enumerateFolderContent | ( | const FolderDescriptor & | _rFolder, |
IEnumerationResultHandler * | _pResultHandler | ||
) |
enumerates the content of a given folder
_rFolder | the folder whose content is to be enumerated |
_pFilter | a filter to apply to the found contents |
_pResultHandler | an instance which should handle the results of the enumeration |
Definition at line 114 of file contentenumeration.cxx.
References svt::FolderDescriptor::aContent, ucbhelper::Content::get(), salhelper::Thread::launch(), m_aFolder, m_aMutex, m_pResultHandler, and svt::FolderDescriptor::sURL.
EnumerationResult svt::FileViewContentEnumerator::enumerateFolderContentSync | ( | const FolderDescriptor & | _rFolder, |
const css::uno::Sequence< OUString > & | rDenyList | ||
) |
enumerates the content of a given folder synchronously
Definition at line 100 of file contentenumeration.cxx.
References enumerateFolderContent(), m_aFolder, m_aMutex, m_pResultHandler, and m_rDenyList.
|
overrideprivatevirtual |
Implements salhelper::Thread.
Definition at line 313 of file contentenumeration.cxx.
References enumerateFolderContent().
|
private |
Definition at line 305 of file contentenumeration.cxx.
References comphelper::findValue(), and m_rDenyList.
Referenced by enumerateFolderContent().
|
private |
Definition at line 169 of file contentenumeration.hxx.
Referenced by cancel(), enumerateFolderContent(), and enumerateFolderContentSync().
|
mutableprivate |
Definition at line 167 of file contentenumeration.hxx.
Referenced by cancel(), enumerateFolderContent(), and enumerateFolderContentSync().
|
private |
Definition at line 173 of file contentenumeration.hxx.
Referenced by cancel(), and enumerateFolderContent().
|
private |
Definition at line 172 of file contentenumeration.hxx.
Referenced by cancel(), enumerateFolderContent(), and enumerateFolderContentSync().
|
private |
Definition at line 164 of file contentenumeration.hxx.
Referenced by enumerateFolderContent().
|
private |
Definition at line 165 of file contentenumeration.hxx.
Referenced by enumerateFolderContent().
|
private |
Definition at line 175 of file contentenumeration.hxx.
Referenced by enumerateFolderContentSync(), and URLOnDenyList().
|
private |
Definition at line 171 of file contentenumeration.hxx.
Referenced by enumerateFolderContent().