Språk

ApnSetting.Builder.SetProxyAddress Method

Definition

Overloads

Name Description
SetProxyAddress(InetAddress)

Sets the address of an HTTP proxy for the APN.

SetProxyAddress(String)

Sets the proxy address of the APN.

SetProxyAddress(InetAddress)

Sets the address of an HTTP proxy for the APN.

[Android.Runtime.Register("setProxyAddress", "(Ljava/net/InetAddress;)Landroid/telephony/data/ApnSetting$Builder;", "GetSetProxyAddress_Ljava_net_InetAddress_Handler", ApiSince=28)]
public virtual Android.Telephony.Data.ApnSetting.Builder? SetProxyAddress(Java.Net.InetAddress? proxy);
[<Android.Runtime.Register("setProxyAddress", "(Ljava/net/InetAddress;)Landroid/telephony/data/ApnSetting$Builder;", "GetSetProxyAddress_Ljava_net_InetAddress_Handler", ApiSince=28)>]
abstract member SetProxyAddress : Java.Net.InetAddress -> Android.Telephony.Data.ApnSetting.Builder
override this.SetProxyAddress : Java.Net.InetAddress -> Android.Telephony.Data.ApnSetting.Builder

Parameters

proxy
InetAddress

the proxy address to set for the APN

Returns

Attributes

Remarks

This method was deprecated in API level 29. use setProxyAddress(String) instead.

Sets the address of an HTTP proxy for the APN. The proxy address can be an IP address or hostname. If proxy contains both an IP address and hostname, this method ignores the IP address.

The InetAddress methods getAllByName() require DNS for hostname resolution. To avoid this requirement when setting a hostname, call InetAddress.getByAddress(java.lang.String, byte[]) with both the hostname and a placeholder IP address. See above for an example.

Android reference for android.telephony.data.ApnSetting.Builder.setProxyAddress.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

SetProxyAddress(String)

Sets the proxy address of the APN.

[Android.Runtime.Register("setProxyAddress", "(Ljava/lang/String;)Landroid/telephony/data/ApnSetting$Builder;", "GetSetProxyAddress_Ljava_lang_String_Handler", ApiSince=29)]
public virtual Android.Telephony.Data.ApnSetting.Builder SetProxyAddress(string? proxy);
[<Android.Runtime.Register("setProxyAddress", "(Ljava/lang/String;)Landroid/telephony/data/ApnSetting$Builder;", "GetSetProxyAddress_Ljava_lang_String_Handler", ApiSince=29)>]
abstract member SetProxyAddress : string -> Android.Telephony.Data.ApnSetting.Builder
override this.SetProxyAddress : string -> Android.Telephony.Data.ApnSetting.Builder

Parameters

proxy
String

the proxy address to set for the APN. This value may be null.

Returns

Attributes

Remarks

Sets the proxy address of the APN.

Android reference for android.telephony.data.ApnSetting.Builder.setProxyAddress.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to