C# Class Senparc.Weixin.MP.TenPayLib.TenPayHttpClient

Mostrar archivo Open project: JeffreySu/WeiXinMPSDK Class Usage Examples

Public Methods

Method Description
Call ( ) : bool

执行http调用

CheckValidationResult ( object sender, X509Certificate certificate, X509Chain chain, SslPolicyErrors errors ) : bool

验证服务器证书

GetErrInfo ( ) : string

获取错误信息

GetResContent ( ) : string

获取结果内容

GetResponseCode ( ) : int

获取http状态码

SetCaInfo ( string caFile ) : void

设置ca

SetCertInfo ( string certFile, string certPasswd ) : void

设置证书信息

SetCharset ( string charset ) : void
SetMethod ( string method ) : void

设置请求方法post或者get

SetReqContent ( string reqContent ) : void

设置请求内容

SetTimeOut ( int timeOut ) : void

设置超时时间,以秒为单位

TenPayHttpClient ( ) : System

Method Details

Call() public method

执行http调用
public Call ( ) : bool
return bool

CheckValidationResult() public method

验证服务器证书
public CheckValidationResult ( object sender, X509Certificate certificate, X509Chain chain, SslPolicyErrors errors ) : bool
sender object
certificate System.Security.Cryptography.X509Certificates.X509Certificate
chain System.Security.Cryptography.X509Certificates.X509Chain
errors SslPolicyErrors
return bool

GetErrInfo() public method

获取错误信息
public GetErrInfo ( ) : string
return string

GetResContent() public method

获取结果内容
public GetResContent ( ) : string
return string

GetResponseCode() public method

获取http状态码
public GetResponseCode ( ) : int
return int

SetCaInfo() public method

设置ca
public SetCaInfo ( string caFile ) : void
caFile string
return void

SetCertInfo() public method

设置证书信息
public SetCertInfo ( string certFile, string certPasswd ) : void
certFile string
certPasswd string
return void

SetCharset() public method

public SetCharset ( string charset ) : void
charset string
return void

SetMethod() public method

设置请求方法post或者get
public SetMethod ( string method ) : void
method string
return void

SetReqContent() public method

设置请求内容
public SetReqContent ( string reqContent ) : void
reqContent string
return void

SetTimeOut() public method

设置超时时间,以秒为单位
public SetTimeOut ( int timeOut ) : void
timeOut int
return void

TenPayHttpClient() public method

public TenPayHttpClient ( ) : System
return System