OnSetEndOfFile event/delegate/callback

Filter:

Pascal    C++ (Lib)    C++ (VCL)    C++ (.NET)    C#    VB.NET    Java 

CBFSConnect     See also    

Overview

This event is fired when the OS or the application needs to change the size of the open file.

Declaration

[Pascal]
    property OnSetEndOfFile : TCBSetEndOfFileEvent;
    TCBSetEndOfFileEvent = procedure( Sender : TObject; FileInfo: TCBFileInfo; EndOfFile: Int64 ) of object;

[C++ (Lib)]
    void (__stdcall *CBSetEndOfFileEvent)(void* Sender, CBFileInfo* FileInfo, long long EndOfFile );

[C++ (VCL)]
    typedef void (__closure *TCBSetEndOfFileEvent)( System::TObject* Sender, TCBFileInfo* FileInfo, __int64 & EndOfFile );

[C++ (.NET)]
    public __delegate void CBSetEndOfFileEvent( CBFSConnect^ Sender, CBFileInfo^ FileInfo, Int64 EndOfFile );

[C#]
    public void CBSetEndOfFileEvent( CBFSConnect Sender, CBFileInfo FileInfo, Int64 EndOfFile );

[VB.NET]
    Sub CBSetEndOfFileEvent( ByVal Sender As CBFSConnect, ByVal FileInfo As CBFileInfo, ByVal EndOfFile As Int64 )

[Java]
    void ICbFsFileEvents.onSetEndOfFile( CBFSConnect sender, CBFileInfo fileInfo, long endOfFile );

Parameters

  • Sender - reference to the class that called the delegate/event handler
  • FileInfo - contains the information about the file
  • EndOfFile - new size of the file data

Description

This event is fired when the OS or the application needs to change the size of the open file. Setting the file pointer doesn't require actual space to be allocated.
Read more about contexts.

Error handling

See Error handling topic for detailed information about how to report errors, which occur in the event handlers, back to CBFS Connect.

See also

GetHandleInfo method     OnCloseFile event     OnCreateFile event     OnOpenFile event     OnSetAllocationSize event     OnSetValidDataLength event