Exemplo n.º 1
0
 /// <summary>
 /// Response to the path-related commands, e.g. PWD, MKD.
 /// </summary>
 /// <param name="path">Full path</param>
 /// <param name="encoding">Path encoding to use</param>
 /// <returns>Response to the client with the current path.</returns>
 public static Task <IResponse> Path(string path, Encoding encoding)
 {
     return(Task.FromResult(FtpResponses.Path(path, encoding)));
 }
Exemplo n.º 2
0
 /// <summary>
 /// Response to file-related commands, e.g. MDTM, SIZE.
 /// </summary>
 /// <param name="status">File status info</param>
 /// <returns>Response to the client containing file status.</returns>
 public static Task <IResponse> FileStatus(string status)
 {
     return(Task.FromResult(FtpResponses.FileStatus(status)));
 }
Exemplo n.º 3
0
 /// <summary>
 /// Passive mode listener active.
 /// </summary>
 /// <param name="address">Listener address segments</param>
 /// <param name="port">Listener port number</param>
 /// <returns>Response to the client containing information about passive mode listener.</returns>
 public static Task <IResponse> PassiveMode(byte[] address, int port)
 {
     return(Task.FromResult(FtpResponses.PassiveMode(address, port)));
 }
Exemplo n.º 4
0
 /// <summary>
 /// Response to the <see cref="FtpCommands.Features"/> command.
 /// </summary>
 /// <param name="features">List of supported features</param>
 /// <param name="lineFeed">Line separator sequence</param>
 /// <returns>Response to the client listing features supported by the server.</returns>
 public static Task <IResponse> Features(IEnumerable <string> features, byte[] lineFeed)
 {
     return(Task.FromResult(FtpResponses.Features(features, lineFeed)));
 }