This event is fired when the OS needs to flush the data of the open file or volume.
property OnFlushFile : TCBFlushFileEvent;
TCBFlushFileEvent = procedure(
Sender : TObject;
) of object;
void (__stdcall *CBFlushFileEvent)(void* Sender,
typedef void (__closure *TCBFlushFileEvent)(
public __delegate void CBFlushFileEvent(
public void CBFlushFileEvent(
ByVal Sender As CBFSConnect,
ByVal FileInfo As CBFileInfo
- Sender - reference to the class that called the delegate/event handler
- FileInfo - contains information about the file. Can be nil / NULL / null / Nothing
This event is fired when the OS tells the file system, that file buffers (incuding all possible metadata) must be flushed and written to the backend storage.
FileInfo contains information about the file to be flushed. If FileInfo is empty, your code should attempt to flush everything, related to the disk.
See Error handling topic for detailed information about how to report errors, which occur in the event handlers, back to CBFS Connect.
Throwing ECBFSConnectError exception from this event handler will not cause the OS to abort the operation or display an error message to the user.