Editar

Compartir a través de


MCSession.SendResource(NSUrl, String, MCPeerID, Action<NSError>) Method

Definition

Enqueues for delivery to peerID the resource at resourceUrl.

[Foundation.Export("sendResourceAtURL:withName:toPeer:withCompletionHandler:")]
public virtual Foundation.NSProgress SendResource (Foundation.NSUrl resourceUrl, string resourceName, MultipeerConnectivity.MCPeerID peerID, Action<Foundation.NSError> completionHandler);
abstract member SendResource : Foundation.NSUrl * string * MultipeerConnectivity.MCPeerID * Action<Foundation.NSError> -> Foundation.NSProgress
override this.SendResource : Foundation.NSUrl * string * MultipeerConnectivity.MCPeerID * Action<Foundation.NSError> -> Foundation.NSProgress

Parameters

resourceUrl
NSUrl

The URL to the resource.

resourceName
String

The name of the resource.

peerID
MCPeerID

The ID of the receiving peer.

completionHandler
Action<NSError>

A handler that is run after delivery or failure.

This parameter can be null.

Returns

true if the resource was enqueued for delivery.

Attributes

Remarks

Note that the return value only indicates successful enqueueing of the resource for transmission, not a confirmation of delivery. Delivery success or failure is passed in to the completionHandler.

Applies to