ConnectivityManager Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Stub ConnectivityManager for layoutlib
[Android.Runtime.Register("android/net/ConnectivityManager", DoNotGenerateAcw=true)]
public class ConnectivityManager : Java.Lang.Object
[<Android.Runtime.Register("android/net/ConnectivityManager", DoNotGenerateAcw=true)>]
type ConnectivityManager = class
inherit Object
- Inheritance
- Attributes
Remarks
Java documentation for android.net.ConnectivityManager
.
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.
Constructors
ConnectivityManager(IntPtr, JniHandleOwnership) |
A constructor used when creating managed representations of JNI objects; called by the runtime. |
Fields
ActionBackgroundDataSettingChanged |
Obsolete.
Broadcast Action: The setting for background data usage has changed values. |
ActionCaptivePortalSignIn | |
ActionRestrictBackgroundChanged | |
ConnectivityAction |
Obsolete.
A change in network connectivity has occurred. |
DefaultNetworkPreference |
Obsolete.
If you want to set the default network preference,you can directly change the networkAttributes array in framework's config.xml. |
ExtraCaptivePortal | |
ExtraCaptivePortalUrl | |
ExtraExtraInfo |
Obsolete.
The lookup key for a string that provides optionally supplied extra information about the network state. |
ExtraIsFailover |
Obsolete.
The lookup key for a boolean that indicates whether a connect event is for a network to which the connectivity manager was failing over following a disconnect on another network. |
ExtraNetwork | |
ExtraNetworkInfo |
Obsolete.
The lookup key for a NetworkInfo object. |
ExtraNetworkRequest | |
ExtraNetworkType |
Obsolete.
Network type which triggered a ConnectivityAction broadcast. |
ExtraNoConnectivity |
The lookup key for a boolean that indicates whether there is a complete lack of connectivity, i.e., no network is available. |
ExtraOtherNetworkInfo |
Obsolete.
The lookup key for a NetworkInfo object. |
ExtraReason |
The lookup key for a string that indicates why an attempt to connect to a network failed. |
RestrictBackgroundStatusDisabled | |
RestrictBackgroundStatusEnabled | |
RestrictBackgroundStatusWhitelisted |
Properties
ActiveNetwork | |
ActiveNetworkInfo |
Obsolete.
Returns details about the currently active default data network. |
BackgroundDataSetting |
Obsolete.
Returns the value of the setting for background data usage. |
BoundNetworkForProcess | |
Class |
Returns the runtime class of this |
DefaultProxy | |
Handle |
The handle to the underlying Android instance. (Inherited from Object) |
IsActiveNetworkMetered |
Returns if the currently active data network is metered. |
IsDefaultNetworkActive |
Return whether the data network is currently active. |
JniIdentityHashCode | (Inherited from Object) |
JniPeerMembers | |
NetworkPreference |
Obsolete.
Retrieves the current preferred network type. |
PeerReference | (Inherited from Object) |
ProcessDefaultNetwork |
Obsolete.
Returns the Network currently bound to this process via
BindProcessToNetwork(Network), or |
RestrictBackgroundStatus | |
ThresholdClass |
This API supports the Mono for Android infrastructure and is not intended to be used directly from your code. |
ThresholdType |
This API supports the Mono for Android infrastructure and is not intended to be used directly from your code. |
Methods
AddDefaultNetworkActiveListener(ConnectivityManager+IOnNetworkActiveListener) |
Start listening to reports when the system's default data network is active, meaning it is a good time to perform network traffic. |
BindProcessToNetwork(Network) | |
Clone() |
Creates and returns a copy of this object. (Inherited from Object) |
CreateSocketKeepalive(Network, IpSecManager+UdpEncapsulationSocket, InetAddress, InetAddress, IExecutor, SocketKeepalive+Callback) | |
Dispose() | (Inherited from Object) |
Dispose(Boolean) | (Inherited from Object) |
Equals(Object) |
Indicates whether some other object is "equal to" this one. (Inherited from Object) |
FromContext(Context) | |
GetAllNetworkInfo() |
Obsolete.
Returns connection status information about all network types supported by the device. |
GetAllNetworks() |
Obsolete.
Returns an array of all Network currently tracked by the framework. |
GetConnectionOwnerUid(Int32, InetSocketAddress, InetSocketAddress) | |
GetHashCode() |
Returns a hash code value for the object. (Inherited from Object) |
GetLinkProperties(Network) |
Get the LinkProperties for the given Network. |
GetMultipathPreference(Network) | |
GetNetworkCapabilities(Network) |
Get the NetworkCapabilities for the given Network. |
GetNetworkInfo(ConnectivityType) |
Obsolete.
Returns connection status information about a particular network type. |
GetNetworkInfo(Network) |
Obsolete.
Returns connection status information about a particular Network. |
GetNetworkWatchlistConfigHash() | |
IsNetworkTypeValid(ConnectivityType) |
Obsolete.
Tests if a given integer represents a valid network type. |
JavaFinalize() |
Called by the garbage collector on an object when garbage collection determines that there are no more references to the object. (Inherited from Object) |
Notify() |
Wakes up a single thread that is waiting on this object's monitor. (Inherited from Object) |
NotifyAll() |
Wakes up all threads that are waiting on this object's monitor. (Inherited from Object) |
RegisterBestMatchingNetworkCallback(NetworkRequest, ConnectivityManager+NetworkCallback, Handler) | |
RegisterDefaultNetworkCallback(ConnectivityManager+NetworkCallback) | |
RegisterDefaultNetworkCallback(ConnectivityManager+NetworkCallback, Handler) | |
RegisterNetworkCallback(NetworkRequest, ConnectivityManager+NetworkCallback) |
Registers to receive notifications about all networks which satisfy the given NetworkRequest. |
RegisterNetworkCallback(NetworkRequest, ConnectivityManager+NetworkCallback, Handler) | |
RegisterNetworkCallback(NetworkRequest, PendingIntent) | |
ReleaseNetworkRequest(PendingIntent) | |
RemoveDefaultNetworkActiveListener(ConnectivityManager+IOnNetworkActiveListener) |
Remove network active listener previously registered with M:Android.Net.ConnectivityManager.AddDefaultNetworkActiveListener(.IOnNetworkActiveListener). |
ReportBadNetwork(Network) |
Obsolete.
Report a problem network to the framework. |
ReportNetworkConnectivity(Network, Boolean) | |
RequestBandwidthUpdate(Network) | |
RequestNetwork(NetworkRequest, ConnectivityManager+NetworkCallback) |
Request a network to satisfy a set of NetworkCapabilities. |
RequestNetwork(NetworkRequest, ConnectivityManager+NetworkCallback, Handler) | |
RequestNetwork(NetworkRequest, ConnectivityManager+NetworkCallback, Handler, Int32) | |
RequestNetwork(NetworkRequest, ConnectivityManager+NetworkCallback, Int32) | |
RequestNetwork(NetworkRequest, PendingIntent) | |
RequestRouteToHost(ConnectivityType, Int32) |
Obsolete.
Ensure that a network route exists to deliver traffic to the specified host via the specified network interface. |
RequestRouteToHostAsync(ConnectivityType, Int32) | |
SetHandle(IntPtr, JniHandleOwnership) |
Sets the Handle property. (Inherited from Object) |
SetProcessDefaultNetwork(Network) |
Obsolete.
Binds the current process to |
StartUsingNetworkFeature(ConnectivityType, String) |
Obsolete.
Tells the underlying networking system that the caller wants to begin using the named feature. |
StopUsingNetworkFeature(ConnectivityType, String) |
Obsolete.
Tells the underlying networking system that the caller is finished using the named feature. |
ToArray<T>() | (Inherited from Object) |
ToString() |
Returns a string representation of the object. (Inherited from Object) |
UnregisterFromRuntime() | (Inherited from Object) |
UnregisterNetworkCallback(ConnectivityManager+NetworkCallback) |
Unregisters callbacks about and possibly releases networks originating from RequestNetwork(NetworkRequest, ConnectivityManager+NetworkCallback) and RegisterNetworkCallback(NetworkRequest, PendingIntent) calls. |
UnregisterNetworkCallback(PendingIntent) | |
Wait() |
Causes the current thread to wait until another thread invokes the
|
Wait(Int64) |
Causes the current thread to wait until either another thread invokes the
|
Wait(Int64, Int32) |
Causes the current thread to wait until another thread invokes the
|
Events
DefaultNetworkActive |
Explicit Interface Implementations
IJavaPeerable.Disposed() | (Inherited from Object) |
IJavaPeerable.DisposeUnlessReferenced() | (Inherited from Object) |
IJavaPeerable.Finalized() | (Inherited from Object) |
IJavaPeerable.JniManagedPeerState | (Inherited from Object) |
IJavaPeerable.SetJniIdentityHashCode(Int32) | (Inherited from Object) |
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) | (Inherited from Object) |
IJavaPeerable.SetPeerReference(JniObjectReference) | (Inherited from Object) |
Extension Methods
JavaCast<TResult>(IJavaObject) |
Performs an Android runtime-checked type conversion. |
JavaCast<TResult>(IJavaObject) | |
GetJniTypeName(IJavaPeerable) |