C# Class HCS_Encoder.WebDav.WebDavClient

Mostrar archivo Open project: i-e-b/HLS---Smooth-Encoder Class Usage Examples

Public Methods

Method Description
CreateDir ( string remotePath ) : void

Create a directory on the server

Delete ( string remoteFilePath ) : void

Delete a file on the server

Download ( String remoteFilePath, String localFilePath ) : void

Download a file from the server

List ( ) : void

List files in the root directory

List ( String path ) : void

List files in the given directory

List ( String remoteFilePath, int depth ) : void

List all files present on the server.

Upload ( String localFilePath, String remoteFilePath ) : void

Upload a file to the server

Upload ( String localFilePath, String remoteFilePath, object state ) : void

Upload a file to the server

Upload ( byte fileData, String remoteFilePath, object state ) : void

Upload raw data as a file to the server

Private Methods

Method Description
FinishCreateDir ( IAsyncResult result ) : void
FinishDelete ( IAsyncResult result ) : void
FinishDownload ( IAsyncResult result ) : void
FinishList ( IAsyncResult result ) : void
FinishUpload ( IAsyncResult result ) : void
HTTPRequest ( Uri uri, string requestMethod, string>.IDictionary headers, byte content, string uploadFilePath, AsyncCallback callback, object state ) : void

Perform the WebDAV call and fire the callback when finished.

ReadCallback ( IAsyncResult result ) : void

Submit data asynchronously

getServerUrl ( String path, System.Boolean appendTrailingSlash ) : Uri

Method Details

CreateDir() public method

Create a directory on the server
public CreateDir ( string remotePath ) : void
remotePath string Destination path of the directory on the server
return void

Delete() public method

Delete a file on the server
public Delete ( string remoteFilePath ) : void
remoteFilePath string
return void

Download() public method

Download a file from the server
public Download ( String remoteFilePath, String localFilePath ) : void
remoteFilePath String Source path and filename of the file on the server
localFilePath String Destination path and filename of the file to download on the local filesystem
return void

List() public method

List files in the root directory
public List ( ) : void
return void

List() public method

List files in the given directory
public List ( String path ) : void
path String
return void

List() public method

List all files present on the server.
public List ( String remoteFilePath, int depth ) : void
remoteFilePath String List only files in this path
depth int Recursion depth
return void

Upload() public method

Upload a file to the server
public Upload ( String localFilePath, String remoteFilePath ) : void
localFilePath String Local path and filename of the file to upload
remoteFilePath String Destination path and filename of the file on the server
return void

Upload() public method

Upload a file to the server
public Upload ( String localFilePath, String remoteFilePath, object state ) : void
localFilePath String Local path and filename of the file to upload
remoteFilePath String Destination path and filename of the file on the server
state object Object to pass along with the callback
return void

Upload() public method

Upload raw data as a file to the server
public Upload ( byte fileData, String remoteFilePath, object state ) : void
fileData byte data to upload
remoteFilePath String Destination path and filename of the file on the server
state object Object to pass along with the callback
return void