C# Class RestSharp.FileParameter

Container for files to be uploaded with requests
显示文件 Open project: kevinmcmahon/RestSharp Class Usage Examples

Public Methods

Method Description
Create ( string name, byte data, string filename ) : FileParameter

Creates a file parameter from an array of bytes.

Create ( string name, byte data, string filename, string contentType ) : FileParameter

Creates a file parameter from an array of bytes.

Method Details

Create() public static method

Creates a file parameter from an array of bytes.
public static Create ( string name, byte data, string filename ) : FileParameter
name string The parameter name to use in the request.
data byte The data to use as the file's contents.
filename string The filename to use in the request.
return FileParameter

Create() public static method

Creates a file parameter from an array of bytes.
public static Create ( string name, byte data, string filename, string contentType ) : FileParameter
name string The parameter name to use in the request.
data byte The data to use as the file's contents.
filename string The filename to use in the request.
contentType string The content type to use in the request.
return FileParameter