C# 클래스 LibCurl.Curl

상속: IDisposable
파일 보기 프로젝트 열기: trustme/LibCurlDotNet 1 사용 예제들

공개 메소드들

메소드 설명
Cleanup ( ) : void

Cleanup all resources

DisableVerifySSL ( ) : void

Disable verify SSL

Dispose ( ) : void
EnableCookies ( string file ) : void

Enable cookies and read from the file specified. If the file is not present, it is not created. Use SaveCookies to save to the file.

GetCookies ( ) : SList

Get the current cookies. You must have already have called EnableCookies()

GetError ( CURLcode code ) : string

Get the curl error

GetObject ( IntPtr userdata ) : object

Returns the object passed to a Set...Data function. Cast back to the original object.

Perform ( ) : CURLcode

Perform the curl operation

SaveCookies ( string file ) : void

Save the cookies to the file specified.

SetCustomPostRequest ( ) : CURLcode

Custom "POST" request

SetDebugData ( object data ) : CURLcode

Object to pass to OnDebugCallback.

SetFollowLocation ( bool flag ) : CURLcode

Follow

SetHeader ( SList list ) : CURLcode

Set the Headers

SetHeaderData ( object data ) : CURLcode

Object to pass to OnHeaderCallback.

SetOpt ( CURLoption option, IntPtr param ) : CURLcode

Set the Curl option

SetOpt ( CURLoption option, long param ) : CURLcode

Set the Curl option

SetOpt ( CURLoption option, string parameter ) : CURLcode

Set the Curl option

SetPost ( ) : CURLcode

Post

SetPostFieldSize ( int size ) : CURLcode
SetPostFields ( string postFields ) : CURLcode

Set the post fields

SetProgressData ( object data ) : CURLcode

Object to pass to OnProgressCallback. Use curl.GetObject to convert the passed IntPtr back into the object, then cast.

SetPut ( ) : CURLcode

Put

SetReadData ( object data ) : CURLcode

Object to pass to OnReadCallback. Use curl.GetObject to convert the passed IntPtr back into the object, then cast.

SetTimeout ( int value ) : void

Response timeout

SetUpload ( ) : CURLcode

Upload

SetUploadSize ( int value ) : CURLcode

Set the size of the upload

SetUrl ( string url ) : CURLcode

Set the Url

SetUserAgent ( string agent ) : CURLcode

Set the user agent

SetWriteData ( object data ) : CURLcode

Object to pass to OnWriteCallback.

Verbose ( ) : void

Enable verbose messages

Version ( ) : string

Version of CUrl

비공개 메소드들

메소드 설명
Curl ( ) : System
FreeHandle ( IntPtr &handle ) : void

Free the pinned object

GetHandle ( object obj ) : IntPtr

Pin the object in memory so the C function can find it

curl_easy_cleanup ( IntPtr pCurl ) : void
curl_easy_duphandle ( IntPtr pCurl ) : IntPtr
curl_easy_getinfo ( IntPtr pCurl, CURLINFO info, IntPtr &pInfo ) : CURLcode
curl_easy_getinfo_64 ( IntPtr pCurl, CURLINFO info, double &dblVal ) : CURLcode
curl_easy_init ( ) : IntPtr
curl_easy_perform ( IntPtr pCurl ) : CURLcode
curl_easy_reset ( IntPtr pCurl ) : void
curl_easy_setopt ( IntPtr pCurl, CURLoption opt, IntPtr parm ) : CURLcode
curl_easy_setopt ( IntPtr pCurl, CURLoption opt, _DebugCallbackDelegate callback ) : CURLcode
curl_easy_setopt ( IntPtr pCurl, CURLoption opt, _GenericCallbackDelegate callback ) : CURLcode
curl_easy_setopt ( IntPtr pCurl, CURLoption opt, _ProgressCallbackDelegate callback ) : CURLcode
curl_easy_setopt ( IntPtr pCurl, CURLoption opt, bool parm ) : CURLcode
curl_easy_setopt ( IntPtr pCurl, CURLoption opt, long parm ) : CURLcode
curl_easy_setopt ( IntPtr pCurl, CURLoption opt, string parm ) : CURLcode
curl_easy_strerror ( CURLcode err ) : IntPtr
curl_escape ( String url, int length ) : IntPtr
curl_formfree ( IntPtr pForm ) : void
curl_free ( IntPtr p ) : void
curl_global_cleanup ( ) : void
curl_global_init ( int flags ) : CURLcode
curl_multi_add_handle ( IntPtr pmulti, IntPtr peasy ) : CURLMcode
curl_multi_cleanup ( IntPtr pmulti ) : CURLMcode
curl_multi_init ( ) : IntPtr
curl_multi_perform ( IntPtr pmulti, int &runningHandles ) : CURLMcode
curl_multi_remove_handle ( IntPtr pmulti, IntPtr peasy ) : CURLMcode
curl_multi_strerror ( CURLMcode errorNum ) : IntPtr
curl_share_cleanup ( IntPtr pShare ) : CURLSHcode
curl_share_init ( ) : IntPtr
curl_share_setopt ( IntPtr pShare, CURLSHoption optCode, IntPtr option ) : CURLSHcode
curl_share_strerror ( CURLSHcode errorCode ) : IntPtr
curl_slist_append ( IntPtr slist, string data ) : IntPtr
curl_slist_free_all ( IntPtr pList ) : CURLSHcode
curl_unescape ( String url, int length ) : IntPtr
curl_version ( ) : IntPtr
curl_version_info ( CURLversion ver ) : IntPtr
internal_OnDebugCallback ( IntPtr ptrCurl, CURLINFOTYPE infoType, string message, int size, IntPtr ptrUserdata ) : int
internal_OnHeaderCallback ( IntPtr ptrBuffer, int sz, int nmemb, IntPtr ptrUserdata ) : int
internal_OnReadCallback ( IntPtr ptrBuffer, int sz, int nmemb, IntPtr ptrUserdata ) : int
internal_OnWriteCallback ( IntPtr ptrBuffer, int sz, int nmemb, IntPtr ptrUserdata ) : int
internal_ProgressCallback ( IntPtr ptrUserdata, double dlTotal, double dlNow, double ulTotal, double ulNow ) : int

메소드 상세

Cleanup() 공개 메소드

Cleanup all resources
public Cleanup ( ) : void
리턴 void

DisableVerifySSL() 공개 메소드

Disable verify SSL
public DisableVerifySSL ( ) : void
리턴 void

Dispose() 공개 메소드

public Dispose ( ) : void
리턴 void

EnableCookies() 공개 메소드

Enable cookies and read from the file specified. If the file is not present, it is not created. Use SaveCookies to save to the file.
public EnableCookies ( string file ) : void
file string
리턴 void

GetCookies() 공개 메소드

Get the current cookies. You must have already have called EnableCookies()
public GetCookies ( ) : SList
리턴 SList

GetError() 공개 메소드

Get the curl error
public GetError ( CURLcode code ) : string
code CURLcode
리턴 string

GetObject() 공개 정적인 메소드

Returns the object passed to a Set...Data function. Cast back to the original object.
public static GetObject ( IntPtr userdata ) : object
userdata IntPtr
리턴 object

Perform() 공개 메소드

Perform the curl operation
public Perform ( ) : CURLcode
리턴 CURLcode

SaveCookies() 공개 메소드

Save the cookies to the file specified.
public SaveCookies ( string file ) : void
file string
리턴 void

SetCustomPostRequest() 공개 메소드

Custom "POST" request
public SetCustomPostRequest ( ) : CURLcode
리턴 CURLcode

SetDebugData() 공개 메소드

Object to pass to OnDebugCallback.
public SetDebugData ( object data ) : CURLcode
data object
리턴 CURLcode

SetFollowLocation() 공개 메소드

Follow
public SetFollowLocation ( bool flag ) : CURLcode
flag bool
리턴 CURLcode

SetHeader() 공개 메소드

Set the Headers
public SetHeader ( SList list ) : CURLcode
list SList
리턴 CURLcode

SetHeaderData() 공개 메소드

Object to pass to OnHeaderCallback.
public SetHeaderData ( object data ) : CURLcode
data object
리턴 CURLcode

SetOpt() 공개 메소드

Set the Curl option
public SetOpt ( CURLoption option, IntPtr param ) : CURLcode
option CURLoption
param IntPtr
리턴 CURLcode

SetOpt() 공개 메소드

Set the Curl option
public SetOpt ( CURLoption option, long param ) : CURLcode
option CURLoption
param long
리턴 CURLcode

SetOpt() 공개 메소드

Set the Curl option
public SetOpt ( CURLoption option, string parameter ) : CURLcode
option CURLoption
parameter string
리턴 CURLcode

SetPost() 공개 메소드

Post
public SetPost ( ) : CURLcode
리턴 CURLcode

SetPostFieldSize() 공개 메소드

public SetPostFieldSize ( int size ) : CURLcode
size int
리턴 CURLcode

SetPostFields() 공개 메소드

Set the post fields
public SetPostFields ( string postFields ) : CURLcode
postFields string
리턴 CURLcode

SetProgressData() 공개 메소드

Object to pass to OnProgressCallback. Use curl.GetObject to convert the passed IntPtr back into the object, then cast.
public SetProgressData ( object data ) : CURLcode
data object
리턴 CURLcode

SetPut() 공개 메소드

Put
public SetPut ( ) : CURLcode
리턴 CURLcode

SetReadData() 공개 메소드

Object to pass to OnReadCallback. Use curl.GetObject to convert the passed IntPtr back into the object, then cast.
public SetReadData ( object data ) : CURLcode
data object
리턴 CURLcode

SetTimeout() 공개 메소드

Response timeout
public SetTimeout ( int value ) : void
value int
리턴 void

SetUpload() 공개 메소드

Upload
public SetUpload ( ) : CURLcode
리턴 CURLcode

SetUploadSize() 공개 메소드

Set the size of the upload
public SetUploadSize ( int value ) : CURLcode
value int
리턴 CURLcode

SetUrl() 공개 메소드

Set the Url
public SetUrl ( string url ) : CURLcode
url string
리턴 CURLcode

SetUserAgent() 공개 메소드

Set the user agent
public SetUserAgent ( string agent ) : CURLcode
agent string
리턴 CURLcode

SetWriteData() 공개 메소드

Object to pass to OnWriteCallback.
public SetWriteData ( object data ) : CURLcode
data object
리턴 CURLcode

Verbose() 공개 메소드

Enable verbose messages
public Verbose ( ) : void
리턴 void

Version() 공개 정적인 메소드

Version of CUrl
public static Version ( ) : string
리턴 string