WifiP2pManager Class

Definition

This class provides the API for managing Wi-Fi peer-to-peer connectivity.

[Android.Runtime.Register("android/net/wifi/p2p/WifiP2pManager", DoNotGenerateAcw=true)]
public class WifiP2pManager : Java.Lang.Object
[<Android.Runtime.Register("android/net/wifi/p2p/WifiP2pManager", DoNotGenerateAcw=true)>]
type WifiP2pManager = class
    inherit Object
Inheritance
WifiP2pManager
Attributes

Remarks

Android platform documentation

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

WifiP2pManager(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

Fields

ActionWifiP2pListenStateChanged
ActionWifiP2pRequestResponseChanged
Busy
Obsolete.

Passed with M:Android.Net.Wifi.P2p.WifiP2Manager.IActionListener.OnFailure.

ConnectionRequestAccept
ConnectionRequestDeferShowPinToService
ConnectionRequestDeferToService
ConnectionRequestReject
Error
Obsolete.

Passed with M:Android.Net.Wifi.P2p.WifiP2Manager.IActionListener.OnFailure.

ExtraDiscoveryState

The lookup key for an int that indicates whether p2p discovery has started or stopped.

ExtraListenState
ExtraNetworkInfo

The lookup key for a NetworkInfo object associated with the p2p network.

ExtraP2pDeviceList

The lookup key for a WifiP2pDeviceList object representing the new peer list when WifiP2pPeersChangedAction broadcast is sent.

ExtraRequestConfig
ExtraRequestResponse
ExtraWifiP2pDevice

The lookup key for a WifiP2pDevice object Retrieve with GetParcelableExtra(String).

ExtraWifiP2pGroup

The lookup key for a WifiP2pGroup object associated with the p2p network.

ExtraWifiP2pInfo

The lookup key for a WifiP2pInfo object Retrieve with GetParcelableExtra(String).

ExtraWifiState

The lookup key for an int that indicates whether Wi-Fi p2p is enabled or disabled.

NoServiceRequests
Obsolete.

Passed with M:Android.Net.Wifi.P2p.WifiP2Manager.IActionListener.OnFailure.

P2pUnsupported
Obsolete.

Passed with M:Android.Net.Wifi.P2p.WifiP2Manager.IActionListener.OnFailure.

WifiP2pConnectionChangedAction

Broadcast intent action indicating that the state of Wi-Fi p2p connectivity has changed.

WifiP2pDiscoveryChangedAction

Broadcast intent action indicating that peer discovery has either started or stopped.

WifiP2pDiscoveryStarted

p2p discovery has started

WifiP2pDiscoveryStopped

p2p discovery has stopped

WifiP2pListenStarted
WifiP2pListenStopped
WifiP2pPeersChangedAction

Broadcast intent action indicating that the available peer list has changed.

WifiP2pStateChangedAction

Broadcast intent action to indicate whether Wi-Fi p2p is enabled or disabled.

WifiP2pStateDisabled
Obsolete.

Wi-Fi p2p is disabled.

WifiP2pStateEnabled
Obsolete.

Wi-Fi p2p is enabled.

WifiP2pThisDeviceChangedAction

Broadcast intent action indicating that this device details have changed.

Properties

Class

Returns the runtime class of this Object.

(Inherited from Object)
Handle

The handle to the underlying Android instance.

(Inherited from Object)
IsChannelConstrainedDiscoverySupported
IsGroupClientRemovalSupported
IsGroupOwnerIPv6LinkLocalAddressProvided
IsSetVendorElementsSupported
JniIdentityHashCode (Inherited from Object)
JniPeerMembers
P2pMaxAllowedVendorElementsLengthBytes
PeerReference (Inherited from Object)
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

AddExternalApprover(WifiP2pManager+Channel, MacAddress, WifiP2pManager+IExternalApproverRequestListener)
AddLocalService(WifiP2pManager+Channel, WifiP2pServiceInfo, WifiP2pManager+IActionListener)

Register a local service for service discovery.

AddServiceRequest(WifiP2pManager+Channel, WifiP2pServiceRequest, WifiP2pManager+IActionListener)

Add a service discovery request.

CancelConnect(WifiP2pManager+Channel, WifiP2pManager+IActionListener)

Cancel any ongoing p2p group negotiation

ClearLocalServices(WifiP2pManager+Channel, WifiP2pManager+IActionListener)

Clear all registered local services of service discovery.

ClearServiceRequests(WifiP2pManager+Channel, WifiP2pManager+IActionListener)

Clear all registered service discovery requests.

Clone()

Creates and returns a copy of this object.

(Inherited from Object)
Connect(WifiP2pManager+Channel, WifiP2pConfig, WifiP2pManager+IActionListener)

Start a p2p connection to a device with the specified configuration.

CreateGroup(WifiP2pManager+Channel, WifiP2pConfig, WifiP2pManager+IActionListener)
CreateGroup(WifiP2pManager+Channel, WifiP2pManager+IActionListener)

Create a p2p group with the current device as the group owner.

DiscoverPeers(WifiP2pManager+Channel, WifiP2pManager+IActionListener)

Initiate peer discovery.

DiscoverPeersOnSocialChannels(WifiP2pManager+Channel, WifiP2pManager+IActionListener)
DiscoverPeersOnSpecificFrequency(WifiP2pManager+Channel, Int32, WifiP2pManager+IActionListener)
DiscoverServices(WifiP2pManager+Channel, WifiP2pManager+IActionListener)

Initiate service discovery.

Dispose() (Inherited from Object)
Dispose(Boolean) (Inherited from Object)
Equals(Object)

Indicates whether some other object is "equal to" this one.

(Inherited from Object)
GetHashCode()

Returns a hash code value for the object.

(Inherited from Object)
GetListenState(WifiP2pManager+Channel, IExecutor, IConsumer)
Initialize(Context, Looper, WifiP2pManager+IChannelListener)

Registers the application with the Wi-Fi framework.

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)
RemoveClient(WifiP2pManager+Channel, MacAddress, WifiP2pManager+IActionListener)
RemoveExternalApprover(WifiP2pManager+Channel, MacAddress, WifiP2pManager+IActionListener)
RemoveGroup(WifiP2pManager+Channel, WifiP2pManager+IActionListener)

Remove the current p2p group.

RemoveLocalService(WifiP2pManager+Channel, WifiP2pServiceInfo, WifiP2pManager+IActionListener)

Remove a registered local service added with M:Android.Net.Wifi.P2p.WifiP2pManager.AddLocalService(.Channel,Android.Net.Wifi.P2p.Nsd.WifiP2pServiceInfo,Android.Net.Wifi.P2p.Nsd.WifiP2pServiceInfo)

RemoveServiceRequest(WifiP2pManager+Channel, WifiP2pServiceRequest, WifiP2pManager+IActionListener)
RequestConnectionInfo(WifiP2pManager+Channel, WifiP2pManager+IConnectionInfoListener)

Request device connection info.

RequestDeviceInfo(WifiP2pManager+Channel, WifiP2pManager+IDeviceInfoListener)
RequestDiscoveryState(WifiP2pManager+Channel, WifiP2pManager+IDiscoveryStateListener)
RequestGroupInfo(WifiP2pManager+Channel, WifiP2pManager+IGroupInfoListener)

Request p2p group info.

RequestNetworkInfo(WifiP2pManager+Channel, WifiP2pManager+INetworkInfoListener)
RequestP2pState(WifiP2pManager+Channel, WifiP2pManager+IP2pStateListener)
RequestPeers(WifiP2pManager+Channel, WifiP2pManager+IPeerListListener)

Request the current list of peers.

SetConnectionRequestResult(WifiP2pManager+Channel, MacAddress, Int32, String, WifiP2pManager+IActionListener)
SetConnectionRequestResult(WifiP2pManager+Channel, MacAddress, Int32, WifiP2pManager+IActionListener)
SetDnsSdResponseListeners(WifiP2pManager+Channel, WifiP2pManager+IDnsSdServiceResponseListener, WifiP2pManager+IDnsSdTxtRecordListener)

Register a callback to be invoked on receiving Bonjour service discovery response.

SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
SetServiceResponseListener(WifiP2pManager+Channel, WifiP2pManager+IServiceResponseListener)
SetUpnpServiceResponseListener(WifiP2pManager+Channel, WifiP2pManager+IUpnpServiceResponseListener)

Register a callback to be invoked on receiving upnp service discovery response.

SetVendorElements(WifiP2pManager+Channel, IList<ScanResult.InformationElement>, WifiP2pManager+IActionListener)
SetWfdInfo(WifiP2pManager+Channel, WifiP2pWfdInfo, WifiP2pManager+IActionListener)
StartListening(WifiP2pManager+Channel, WifiP2pManager+IActionListener)
StopListening(WifiP2pManager+Channel, WifiP2pManager+IActionListener)
StopPeerDiscovery(WifiP2pManager+Channel, WifiP2pManager+IActionListener)

Stop an ongoing peer discovery

ToArray<T>() (Inherited from Object)
ToString()

Returns a string representation of the object.

(Inherited from Object)
UnregisterFromRuntime() (Inherited from Object)
Wait()

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>.

(Inherited from Object)
Wait(Int64)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
Wait(Int64, Int32)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)

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)

Applies to