Method SFTPClient():get() Foundation
Downloads file content.
:get( <cRemoteFile> ) --> character
A binary string containing the file content. An empty string is returned in case of an error.
Downloads the content of a remote file into memory. The operation reads the complete content of the specified file.
For large files, consider using the :getFile() method instead, which writes chunks of data to the local file, requiring less memory during the operation.
If the remote file does not exist, the operation fails.
In case of an error condition, use the :getLastError() and :getLastMessage() methods to obtain detailed error information. Note that an empty string result does not necessarily indicate an error, as the file on the server may be empty.
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.