#include <sbFileScan.h>
Public Member Functions | |
sbFileScanQuery () | |
sbFileScanQuery (const nsString &strDirectory, const PRBool &bRecurse, sbIFileScanCallback *pCallback) | |
virtual | ~sbFileScanQuery () |
void | init () |
Public Member Functions inherited from sbIFileScanQuery | |
void | setDirectory (in AString strDirectory) |
Set the directory to scan. More... | |
AString | getDirectory () |
Get the directory to scan. More... | |
void | setRecurse (in PRBool bRecurse) |
Set the scan to run recursively under the given directory. More... | |
PRBool | getRecurse () |
Whether or not the scan will run recursively. More... | |
void | addFileExtension (in AString strExtension) |
void | addFlaggedFileExtension (in AString strExtension) |
Add an extension that will not be added to the final discovered paths but will set the |flaggedExtensionsFound| attribute to true if a file with the specified extension is found during the scan. More... | |
void | setCallback (in sbIFileScanCallback pCallback) |
Set the callback object for the scan. More... | |
sbIFileScanCallback | getCallback () |
Get the callback object for the scan. More... | |
PRUint32 | getFileCount () |
Get the number of files found. More... | |
PRUint32 | getFlaggedFileCount () |
Get the number of flagged files found. More... | |
void | addFilePath (in AString strFilePath) |
USER CODE SHOULD NOT REFERENCE THIS METHOD. More... | |
AString | getFilePath (in PRUint32 nIndex) |
Get the N'th file from the results of the scan. More... | |
AString | getFlaggedFilePath (in PRUint32 nIndex) |
Get the N'th flagged file from the results of the scan. More... | |
PRBool | isScanning () |
Whether or not the scan operation is executing. More... | |
void | setIsScanning (in PRBool bIsScanning) |
USER CODE SHOULD NOT REFERENCE THIS METHOD. More... | |
AString | getLastFileFound () |
Returns the most recent file found by the scan. More... | |
AString | getCurrentScanPath () |
Returns the most recent directory scanned. More... | |
void | setCurrentScanPath (in AString strScanPath) |
USER CODE SHOULD NOT REFERENCE THIS METHOD. More... | |
void | cancel () |
Cancel the current scanning loop. More... | |
nsIArray | getResultRangeAsURIStrings (in unsigned long aStartIndex, in unsigned long aEndIndex) |
PRBool | isCancelled () |
USER CODE SHOULD NOT REFERENCE THIS METHOD. More... | |
Protected Member Functions | |
nsString | GetExtensionFromFilename (const nsAString &strFilename) |
PRBool | VerifyFileExtension (const nsAString &strExtension, PRBool *aOutIsFlaggedExtension) |
Protected Attributes | |
PRLock * | m_pDirectoryLock |
nsString | m_strDirectory |
PRLock * | m_pCurrentPathLock |
nsString | m_strCurrentPath |
PRBool | m_bSearchHidden |
PRBool | m_bRecurse |
PRBool | m_bWantLibraryContentURIs |
PRLock * | m_pScanningLock |
PRBool | m_bIsScanning |
PRLock * | m_pCallbackLock |
nsCOMPtr< sbIFileScanCallback > | m_pCallback |
nsCOMPtr< nsIMutableArray > | m_pFileStack |
nsCOMPtr< nsIMutableArray > | m_pFlaggedFileStack |
PRLock * | m_pExtensionsLock |
nsTHashtable< nsStringHashKey > | m_Extensions |
PRLock * | m_pFlaggedFileExtensionsLock |
nsTHashtable< nsStringHashKey > | m_FlaggedExtensions |
nsString | m_lastSeenExtension |
PRLock * | m_pCancelLock |
PRBool | m_bCancel |
Additional Inherited Members | |
Public Attributes inherited from sbIFileScanQuery | |
attribute boolean | searchHidden |
readonly attribute boolean | flaggedExtensionsFound |
Returns true if a flagged file extension set in |addFlaggedFileExtension()| was found during the file scan. More... | |
attribute boolean | wantLibraryContentURIs |
Definition at line 82 of file sbFileScan.h.
sbFileScanQuery::sbFileScanQuery | ( | ) |
To log this module, set the following environment variable: NSPR_LOG_MODULES=sbMediaImportFileScan:5
Definition at line 70 of file sbFileScan.cpp.
sbFileScanQuery::sbFileScanQuery | ( | const nsString & | strDirectory, |
const PRBool & | bRecurse, | ||
sbIFileScanCallback * | pCallback | ||
) |
|
virtual |
Definition at line 151 of file sbFileScan.cpp.
|
protected |
Definition at line 546 of file sbFileScan.cpp.
void sbFileScanQuery::init | ( | ) |
|
protected |
Definition at line 558 of file sbFileScan.cpp.
|
protected |
Definition at line 132 of file sbFileScan.h.
|
protected |
Definition at line 113 of file sbFileScan.h.
|
protected |
Definition at line 109 of file sbFileScan.h.
|
protected |
Definition at line 108 of file sbFileScan.h.
|
protected |
Definition at line 110 of file sbFileScan.h.
|
protected |
Definition at line 123 of file sbFileScan.h.
|
protected |
Definition at line 126 of file sbFileScan.h.
|
protected |
Definition at line 129 of file sbFileScan.h.
|
protected |
Definition at line 116 of file sbFileScan.h.
|
protected |
Definition at line 115 of file sbFileScan.h.
|
protected |
Definition at line 131 of file sbFileScan.h.
|
protected |
Definition at line 105 of file sbFileScan.h.
|
protected |
Definition at line 102 of file sbFileScan.h.
|
protected |
Definition at line 122 of file sbFileScan.h.
|
protected |
Definition at line 119 of file sbFileScan.h.
|
protected |
Definition at line 125 of file sbFileScan.h.
|
protected |
Definition at line 120 of file sbFileScan.h.
|
protected |
Definition at line 112 of file sbFileScan.h.
|
protected |
Definition at line 106 of file sbFileScan.h.
|
protected |
Definition at line 103 of file sbFileScan.h.