CkoSFtpDir Swift Reference Documentation


Represents a remote SFTP directory listing.


NumFilesAndDirs: Int (read-only)

The number of entries in this directory listing.

OriginalPath: String (read-only)

The original path used to fetch this directory listing. This is the string that was originally passed to the OpenDir method when the directory was read.


GetFileObject(index: Int) -> CkoSFtpFile

Returns the Nth entry in the directory. Indexing begins at 0.

GetFilename(index: Int) -> String

Returns the Nth filename in the directory (indexing begins at 0).

Returns true for success, false for failure.

LoadTaskResult(task: CkoTask) -> Bool

Introduced in version

Loads the SFTP directory object from a completed asynchronous task.

Returns true for success, false for failure.