summaryrefslogtreecommitdiff
path: root/zen/file_handling.h
diff options
context:
space:
mode:
authorDaniel Wilhelm <daniel@wili.li>2014-04-18 17:17:51 +0200
committerDaniel Wilhelm <daniel@wili.li>2014-04-18 17:17:51 +0200
commit237aedc590b58c0e69d7dfcac92b5f767b7c004a (patch)
tree83f361a82ba483f2daf83b677e8685cd953812d9 /zen/file_handling.h
parent4.5 (diff)
downloadFreeFileSync-237aedc590b58c0e69d7dfcac92b5f767b7c004a.tar.gz
FreeFileSync-237aedc590b58c0e69d7dfcac92b5f767b7c004a.tar.bz2
FreeFileSync-237aedc590b58c0e69d7dfcac92b5f767b7c004a.zip
4.6
Diffstat (limited to 'zen/file_handling.h')
-rw-r--r--zen/file_handling.h16
1 files changed, 11 insertions, 5 deletions
diff --git a/zen/file_handling.h b/zen/file_handling.h
index 8ffe38d0..e6819322 100644
--- a/zen/file_handling.h
+++ b/zen/file_handling.h
@@ -47,7 +47,7 @@ void setFileTime(const Zstring& filename, const Int64& modificationTime, ProcSym
UInt64 getFilesize(const Zstring& filename); //throw FileError
//file handling
-bool removeFile(const Zstring& filename); //return "true" if file was actually deleted; throw (FileError)
+bool removeFile(const Zstring& filename); //return "true" if file was actually deleted; throw FileError
void removeDirectory(const Zstring& directory, CallbackRemoveDir* callback = NULL); //throw FileError
@@ -93,8 +93,8 @@ void copySymlink(const Zstring& sourceLink, const Zstring& targetLink, bool copy
struct CallbackRemoveDir
{
virtual ~CallbackRemoveDir() {}
- virtual void notifyFileDeletion(const Zstring& filename) = 0;
- virtual void notifyDirDeletion(const Zstring& dirname) = 0;
+ virtual void notifyFileDeletion(const Zstring& filename) = 0; //one call for each (existing) object!
+ virtual void notifyDirDeletion (const Zstring& dirname ) = 0; //
};
@@ -115,8 +115,14 @@ struct CallbackCopyFile //callback functionality
struct CallbackMoveFile //callback functionality
{
- virtual ~CallbackMoveFile() {}
- virtual void requestUiRefresh(const Zstring& currentObject) = 0; //see CallbackCopyFile!
+ virtual ~CallbackMoveFile() {} //see CallbackCopyFile for limitations when trowing exceptions!
+
+ virtual void onBeforeFileMove(const Zstring& fileFrom, const Zstring& fileTo) = 0; //one call before each (planned) move
+ virtual void onBeforeDirMove (const Zstring& dirFrom, const Zstring& dirTo ) = 0; //
+ virtual void objectProcessed() = 0; //one call after each completed move (count objects total)
+
+ //called frequently if move has to revert to copy + delete:
+ virtual void updateStatus(Int64 bytesDelta) = 0;
};
}
bgstack15