mirror of
https://gitee.com/durcframework/SOP.git
synced 2025-08-11 21:57:56 +08:00
SDK可指定requestMethod
This commit is contained in:
@@ -8,33 +8,33 @@ namespace SDKCSharp.Common
|
||||
{
|
||||
public class RequestForm
|
||||
{
|
||||
|
||||
private Dictionary<string, string> form;
|
||||
|
||||
/// <summary>
|
||||
/// 请求表单内容
|
||||
/// </summary>
|
||||
public Dictionary<string, string> Form
|
||||
{
|
||||
get { return form; }
|
||||
set { form = value; }
|
||||
}
|
||||
|
||||
private List<UploadFile> files;
|
||||
public Dictionary<string, string> Form { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 上传文件
|
||||
/// </summary>
|
||||
public List<UploadFile> Files
|
||||
{
|
||||
get { return files; }
|
||||
set { files = value; }
|
||||
}
|
||||
public List<UploadFile> Files { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 指定或者设置字符集
|
||||
/// </summary>
|
||||
/// <value>The charset.</value>
|
||||
public Encoding Charset { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 指定或设置HTTP请求method
|
||||
/// </summary>
|
||||
/// <value>The request method.</value>
|
||||
public RequestMethod RequestMethod { get; set; } = RequestMethod.POST;
|
||||
|
||||
public RequestForm(Dictionary<string, string> form)
|
||||
{
|
||||
this.form = form;
|
||||
this.Form = form;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
8
sop-sdk/sdk-csharp/SDKCSharp/Common/RequestMethod.cs
Normal file
8
sop-sdk/sdk-csharp/SDKCSharp/Common/RequestMethod.cs
Normal file
@@ -0,0 +1,8 @@
|
||||
using System;
|
||||
namespace SDKCSharp.Common
|
||||
{
|
||||
public enum RequestMethod
|
||||
{
|
||||
GET, HEAD, POST, PUT, PATCH, DELETE, OPTIONS, TRACE
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user