type

TScSFTPServerReadDirectoryEvent = procedure(Sender: TObject; SFTPSessionInfo: TScSFTPSessionInfo; Data: TObject; FileInfo: TScSFTPFileInfo; var Error: TScSFTPError) of object;

 

property OnReadDirectory: TScSFTPServerReadDirectoryEvent;

 

Description

The OnReadDirectory event occurs on request from an SFTP client to search the next file in a directory specified by the Data object and retrieve the information about this file. If a file is not found, the erEof error should be returned.

In order to obtain a complete directory listing, the user can process this request until the erEof error will be returned.

You can call the DefaultReadDirectory method to execute this operation or write your own implementation.

 

Parameters:

Sender - the object whose event handler is called.
SFTPSessionInfo - contains the information about the current SFTP session.
Data - specifies the information about a reading directory as the TScSearchRec object or any user's object. Usually this object is previously returned by the DefaultOpenDirectory method or the OnOpenDirectory event handler.
FileInfo - the object that will contain the information about the found file.
Error - a parameter to pass the information about an error that can arise when reading a directory. The erEof error should be returned if file is not found.

 

See also

DefaultReadDirectory

SecureBridge Components, Copyright © 2007-2024 Devart. All Rights Reserved. Provide Feedback Visit Forum Request Support