Redigeeri

Jagamisviis:


PeerContact.Invite Method

Definition

Sends an invitation to join into peer collaboration activity sponsored by the sender.

Overloads

Invite(PeerApplication, String, Byte[])

Sends the specified invitation to join into the specified PeerApplication sponsored by the sender.

Invite(PeerEndPoint, PeerApplication, String, Byte[])

Sends the specified invitation to the specified PeerEndPoint to join into the specified PeerCollaboration application sponsored by the sender.

Invite()

Sends an invitation to join into peer collaboration sponsored by the sender.

Invite(PeerEndPoint)

Sends an invitation to a specific endpoint to join into peer collaboration with the sender of the invitation.

Remarks

The caller is not required to sign-in to the System.Net.PeerToPeer.Collaboration infrastructure for this method to complete successfully. A PeerInvitationResponse from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined.

Invite(PeerApplication, String, Byte[])

Sends the specified invitation to join into the specified PeerApplication sponsored by the sender.

public:
 override System::Net::PeerToPeer::Collaboration::PeerInvitationResponse ^ Invite(System::Net::PeerToPeer::Collaboration::PeerApplication ^ applicationToInvite, System::String ^ message, cli::array <System::Byte> ^ invitationData);
[System.Security.SecurityCritical]
public override System.Net.PeerToPeer.Collaboration.PeerInvitationResponse Invite (System.Net.PeerToPeer.Collaboration.PeerApplication applicationToInvite, string message, byte[] invitationData);
[<System.Security.SecurityCritical>]
override this.Invite : System.Net.PeerToPeer.Collaboration.PeerApplication * string * byte[] -> System.Net.PeerToPeer.Collaboration.PeerInvitationResponse
Public Overrides Function Invite (applicationToInvite As PeerApplication, message As String, invitationData As Byte()) As PeerInvitationResponse

Parameters

applicationToInvite
PeerApplication

The PeerApplication for which the invitation is sent.

message
String

A message to send to the remote peer along with the application invitation.

invitationData
Byte[]

A user-defined data blob to associate with the invitation. Its size can be no more than 16,384 bytes.

Returns

A PeerInvitationResponse from the peer who received the invitation.

Attributes

Exceptions

The PeerEndPoint object has been disposed.

The Id for the current application does not exist or is empty.

Remarks

The caller is not required to sign-in to the System.Net.PeerToPeer.Collaboration infrastructure for this method to complete successfully. A PeerInvitationResponse from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined.

Calling this method requires a PermissionState of Unrestricted. This state is created when the peer collaboration session begins.

Notes to Callers

Calling this method requires a PermissionState of Unrestricted. This state is created when the peer collaboration session begins.

See also

Applies to

Invite(PeerEndPoint, PeerApplication, String, Byte[])

Sends the specified invitation to the specified PeerEndPoint to join into the specified PeerCollaboration application sponsored by the sender.

public:
 System::Net::PeerToPeer::Collaboration::PeerInvitationResponse ^ Invite(System::Net::PeerToPeer::Collaboration::PeerEndPoint ^ peerEndPoint, System::Net::PeerToPeer::Collaboration::PeerApplication ^ applicationToInvite, System::String ^ message, cli::array <System::Byte> ^ invitationData);
[System.Security.SecurityCritical]
public System.Net.PeerToPeer.Collaboration.PeerInvitationResponse Invite (System.Net.PeerToPeer.Collaboration.PeerEndPoint peerEndPoint, System.Net.PeerToPeer.Collaboration.PeerApplication applicationToInvite, string message, byte[] invitationData);
[<System.Security.SecurityCritical>]
override this.Invite : System.Net.PeerToPeer.Collaboration.PeerEndPoint * System.Net.PeerToPeer.Collaboration.PeerApplication * string * byte[] -> System.Net.PeerToPeer.Collaboration.PeerInvitationResponse
Public Function Invite (peerEndPoint As PeerEndPoint, applicationToInvite As PeerApplication, message As String, invitationData As Byte()) As PeerInvitationResponse

Parameters

peerEndPoint
PeerEndPoint

The endpoint or remote peer to which to send the invitation.

applicationToInvite
PeerApplication

The application for which the invitation is sent.

message
String

A message to send to the remote peer along with the application invitation. The message can be no more than 255 Unicode characters.

invitationData
Byte[]

A user-defined data blob to associate with the invitation. Its size can be no more than 16,384 bytes.

Returns

A PeerInvitationResponse from the peer who received the invitation.

Attributes

Exceptions

Endpoint in PeerEndPoint cannot be null.

The PeerEndPoint object has been disposed.

The Id for the current application does not exist or is empty.

Remarks

The caller is not required to sign-in to the System.Net.PeerToPeer.Collaboration infrastructure for this method to complete successfully. A PeerInvitationResponse from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined.

Notes to Callers

Calling this method requires a PermissionState of Unrestricted. This state is created when the peer collaboration session begins.

See also

Applies to

Invite()

Sends an invitation to join into peer collaboration sponsored by the sender.

public:
 override System::Net::PeerToPeer::Collaboration::PeerInvitationResponse ^ Invite();
[System.Security.SecurityCritical]
public override System.Net.PeerToPeer.Collaboration.PeerInvitationResponse Invite ();
[<System.Security.SecurityCritical>]
override this.Invite : unit -> System.Net.PeerToPeer.Collaboration.PeerInvitationResponse
Public Overrides Function Invite () As PeerInvitationResponse

Returns

A PeerInvitationResponse from the peer who received the invitation.

Attributes

Exceptions

The PeerEndPoint object has been disposed.

The Id for the current application does not exist.

Remarks

The caller is not required to sign-in to the System.Net.PeerToPeer.Collaboration infrastructure for this method to complete successfully. A PeerInvitationResponse from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined.

Notes to Callers

Calling this method requires a PermissionState of Unrestricted. This state is created when the peer collaboration session begins.

See also

Applies to

Invite(PeerEndPoint)

Sends an invitation to a specific endpoint to join into peer collaboration with the sender of the invitation.

public:
 System::Net::PeerToPeer::Collaboration::PeerInvitationResponse ^ Invite(System::Net::PeerToPeer::Collaboration::PeerEndPoint ^ peerEndPoint);
[System.Security.SecurityCritical]
public System.Net.PeerToPeer.Collaboration.PeerInvitationResponse Invite (System.Net.PeerToPeer.Collaboration.PeerEndPoint peerEndPoint);
[<System.Security.SecurityCritical>]
override this.Invite : System.Net.PeerToPeer.Collaboration.PeerEndPoint -> System.Net.PeerToPeer.Collaboration.PeerInvitationResponse
Public Function Invite (peerEndPoint As PeerEndPoint) As PeerInvitationResponse

Parameters

peerEndPoint
PeerEndPoint

The endpoint to receive the invitation.

Returns

A PeerInvitationResponse from the peer endpoint who received the invitation.

Attributes

Exceptions

The PeerEndPoint object has been disposed.

  • Unable to complete Invite() operation.

  • The currently executing application is not registered with the peer collaboration infrastructure.

  • EndPoint specified by PeerEndPoint object is not valid.

Remarks

The caller is not required to sign-in to the System.Net.PeerToPeer.Collaboration infrastructure for this method to complete successfully. A PeerInvitationResponse from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined.

Notes to Callers

Calling this method requires a PermissionState of Unrestricted. This state is created when the peer collaboration session begins.

See also

Applies to