語言

BasicHttpProcessor.AddInterceptor 方法

定義

多載

名稱 Description
AddInterceptor(IHttpRequestInterceptor)

與 AddRequestInterceptor(IHttpRequestInterceptor) 相同。

AddInterceptor(IHttpResponseInterceptor)

與 AddResponseInterceptor(IHttpResponseInterceptor) 相同。

AddInterceptor(IHttpRequestInterceptor, Int32)

在請求攔截器列表中指定位置插入一個請求攔截器。

AddInterceptor(IHttpResponseInterceptor, Int32)

在回應攔截器列表中指定位置插入一個響應攔截器。

AddInterceptor(IHttpRequestInterceptor)

[Android.Runtime.Register("addInterceptor", "(Lorg/apache/http/HttpRequestInterceptor;)V", "")]
public void AddInterceptor(Org.Apache.Http.IHttpRequestInterceptor? interceptor);
[<Android.Runtime.Register("addInterceptor", "(Lorg/apache/http/HttpRequestInterceptor;)V", "")>]
member this.AddInterceptor : Org.Apache.Http.IHttpRequestInterceptor -> unit

參數

interceptor
IHttpRequestInterceptor

攔截機要補充

屬性

備註

此頁面的部分是根據 Android 開放原始碼專案所建立和共用的工作進行修改,並根據 Creative Commons 2.5 屬性授權中所述的詞彙使用。

適用於

AddInterceptor(IHttpResponseInterceptor)

[Android.Runtime.Register("addInterceptor", "(Lorg/apache/http/HttpResponseInterceptor;)V", "")]
public void AddInterceptor(Org.Apache.Http.IHttpResponseInterceptor? interceptor);
[<Android.Runtime.Register("addInterceptor", "(Lorg/apache/http/HttpResponseInterceptor;)V", "")>]
member this.AddInterceptor : Org.Apache.Http.IHttpResponseInterceptor -> unit

參數

interceptor
IHttpResponseInterceptor

攔截機要補充

屬性

備註

此頁面的部分是根據 Android 開放原始碼專案所建立和共用的工作進行修改,並根據 Creative Commons 2.5 屬性授權中所述的詞彙使用。

適用於

AddInterceptor(IHttpRequestInterceptor, Int32)

在請求攔截器列表中指定位置插入一個請求攔截器。

[Android.Runtime.Register("addInterceptor", "(Lorg/apache/http/HttpRequestInterceptor;I)V", "")]
public void AddInterceptor(Org.Apache.Http.IHttpRequestInterceptor? interceptor, int index);
[<Android.Runtime.Register("addInterceptor", "(Lorg/apache/http/HttpRequestInterceptor;I)V", "")>]
member this.AddInterceptor : Org.Apache.Http.IHttpRequestInterceptor * int -> unit

參數

interceptor
IHttpRequestInterceptor

請求攔截器插入。 null在索引檢查為負值後,攔截器會被忽略。

index
Int32

零基插入指數。 對於非零攔截器,這個數值必須介於零與請求攔截器數量之間,包含在內。

屬性

備註

此頁面的部分是根據 Android 開放原始碼專案所建立和共用的工作進行修改,並根據 Creative Commons 2.5 屬性授權中所述的詞彙使用。

適用於

AddInterceptor(IHttpResponseInterceptor, Int32)

在回應攔截器列表中指定位置插入一個響應攔截器。

[Android.Runtime.Register("addInterceptor", "(Lorg/apache/http/HttpResponseInterceptor;I)V", "")]
public void AddInterceptor(Org.Apache.Http.IHttpResponseInterceptor? interceptor, int index);
[<Android.Runtime.Register("addInterceptor", "(Lorg/apache/http/HttpResponseInterceptor;I)V", "")>]
member this.AddInterceptor : Org.Apache.Http.IHttpResponseInterceptor * int -> unit

參數

interceptor
IHttpResponseInterceptor

回應攔截器插入。 null在索引檢查為負值後,攔截器會被忽略。

index
Int32

零基插入指數。 對於非零截擊器,這個值必須介於零與響應攔截器數量之間,包含在內。

屬性

備註

此頁面的部分是根據 Android 開放原始碼專案所建立和共用的工作進行修改,並根據 Creative Commons 2.5 屬性授權中所述的詞彙使用。

適用於