RemoteSystemSessionInvitationListener
RemoteSystemSessionInvitationListener
RemoteSystemSessionInvitationListener
RemoteSystemSessionInvitationListener
Class
Definition
Contains the functionality for receiving and handling invitations to join remote sessions. This class begins listening for invitations when it is instantiated.
public : sealed class RemoteSystemSessionInvitationListener : IRemoteSystemSessionInvitationListenerpublic sealed class RemoteSystemSessionInvitationListener : IRemoteSystemSessionInvitationListenerPublic NotInheritable Class RemoteSystemSessionInvitationListener Implements IRemoteSystemSessionInvitationListener// You can use this class in JavaScript.
- Attributes
Windows 10 requirements
| Device family |
Windows 10 Creators Update (introduced v10.0.15063.0)
|
| API contract |
Windows.Foundation.UniversalApiContract (introduced v4)
|
Examples
See the following code for an example of how to receive and handle remote session invitations.
public void SubscribeAndHandleInvites() {
var invitationListener = new RemoteSystemSessionInvitationListener();
// register the following code to handle this event:
invitationListener.InvitationReceived += async (sender, args) => {
// issue a join request to the session
RemoteSystemSessionJoinResult joinResult = await args.Invitation.RemoteSystemSessionInfo.JoinAsync();
// handle the join result as in the normal session discovery scenario
// ...
};
}
Constructors
RemoteSystemSessionInvitationListener() RemoteSystemSessionInvitationListener() RemoteSystemSessionInvitationListener() RemoteSystemSessionInvitationListener()
Initializes an instance of RemoteSystemSessionInvitationListener.
public : RemoteSystemSessionInvitationListener()public RemoteSystemSessionInvitationListener()Public Sub New()// You can use this method in JavaScript.
Events
InvitationReceived InvitationReceived InvitationReceived InvitationReceived
Raised when a remote session invitation from another device has been detected.
public : event TypedEventHandler InvitationReceived<RemoteSystemSessionInvitationListener, RemoteSystemSessionInvitationReceivedEventArgs>public event TypedEventHandler InvitationReceived<RemoteSystemSessionInvitationListener, RemoteSystemSessionInvitationReceivedEventArgs>Public Event InvitationReceived<RemoteSystemSessionInvitationListener, RemoteSystemSessionInvitationReceivedEventArgs>// You can use this event in JavaScript.