Discuss this help topic in SecureBlackbox Forum

TElSimpleSFTPClient.RequestAttributes

TElSimpleSFTPClient     See also     


Filter: C#  VB.NET  Pascal  C++  PHP  Java  


Retrieves the attributes for a specified file

Declaration

[C#]
    void RequestAttributes(string Path, bool FollowSymLinks, TElSftpFileAttributes Attributes);
    void RequestAttributes(byte[] Handle, TElSftpFileAttributes Attributes);

[VB.NET]
    Sub RequestAttributes(ByVal Path As String, ByVal FollowSymLinks As Boolean, ByVal Attributes As TElSftpFileAttributes)
    Sub RequestAttributes(ByVal Handle As Byte(), ByVal Attributes As TElSftpFileAttributes)

[Pascal]
    procedure RequestAttributes(const Path : string; FollowSymLinks : boolean; Attributes : TElSftpFileAttributes); overload;
    procedure RequestAttributes(const Handle : TSBSftpFileHandle; Attributes : TElSftpFileAttributes); overload;

[C++]
    void RequestAttributes(const std::string &Path, bool FollowSymLinks, TElSftpFileAttributes &Attributes);
    void RequestAttributes(const std::string &Path, bool FollowSymLinks, TElSftpFileAttributes *Attributes);
    void RequestAttributes(const std::vector<uint8_t> &Handle, TElSftpFileAttributes &Attributes);
    void RequestAttributes(const std::vector<uint8_t> &Handle, TElSftpFileAttributes *Attributes);

[PHP]
    void RequestAttributes(string $Path, bool $FollowSymLinks, TElSftpFileAttributes $Attributes)
    void RequestAttributes(array of byte|string|NULL $Handle, TElSftpFileAttributes $Attributes)

[Java]
    void requestAttributes(byte[] Handle, TElSftpFileAttributes Attributes);
    void requestAttributes(String Path, boolean FollowSymLinks, TElSftpFileAttributes Attributes);

Parameters

  • Path - path name
  • FollowSymLinks - specifies whether SFTP should follow symbolic links
  • Attributes - object with attributes
  • Handle - handle to opened file

Description

    Use this method to retrieve attributes for a specified file. Set Attributes.IncludedAttributes property to the set of attributes which you need to query. If the attributes were not successfully retrieved, the OnError event is fired. Otherwise, all or some of the specified attributes are set. Check Attributes.IncludedAttributes property to find out, what attributes were actually returned.
    In case of error, EElSFTPError exception containing SFTP error code, is raised. For more information on error handling, please read the corresponding how-to article.

See also:     SetAttributes    

Discuss this help topic in SecureBlackbox Forum