Secure FTP Factory for .NET

FtpFileSort Class

Sorts a enumeration of

FtpFile
. The user have to specify a comparator instance which will be used by the sort algorithm. The sort is made by default in ascendent way, however, you can change that property. The sort can be made by file name, date or size too. To change the sorter field it is necessary to specify the corresponding comparator. The following is an example usage:
    Ftp ftp = new Ftp("ftp.myserver.com","anonymous","user@here.com");
    ftp.Connect();
    
    // Get the remote files enumeration
    IEnumerator e = ftp.GetDirListing();
    
    //Creates the sorter
    FtpFileSort sort = new FtpFileSort(e);
    
    // Ascendent way
    sort.Ascendent = true;
    
    // Sortes the enumeration data
    e = sort.Sort(FtpFileSort.Comparator.date);

For a list of all members of this type, see FtpFileSort Members.

System.Object
   Jscape.Ftp.FtpFileSort

public class FtpFileSort

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Requirements

Namespace: Jscape.Ftp

Assembly: Jscape.Ftp (in Jscape.Ftp.dll)

See Also

FtpFileSort Members | Jscape.Ftp Namespace