BPM通过http协议实现网络传输,语言使用.net(c#),在这里只提供一个接口,具体代码如下,请参照:
public string MakeRequest(string parameters)
{
ServicePointManager.ServerCertificateValidationCallback = new System.Net.Security.RemoteCertificateValidationCallback(CheckValidationResult);//验证服务器证书回调自动验证
var request = (HttpWebRequest)WebRequest.Create(EndPoint + parameters);
request.Method = Method.ToString();
request.ContentLength = 0;
request.ContentType = ContentType;
if (!string.IsNullOrEmpty(PostData) && Method == HttpVerb.POST)//如果传送的数据不为空,并且方法是post
{
var encoding = new UTF8Encoding();
var bytes = Encoding.GetEncoding("utf-8").GetBytes(PostData);//编码方式按需求进行更改,UTF-8
request.ContentLength = bytes.Leng