Share via


XboxLiveDeviceAddress.SnapshotChanged Event

Definition

Event raised when the snapshot for this XboxLiveDeviceAddress has changed.

Snapshots are serialized forms of XboxLiveDeviceAddress objects that can be transmitted to remote devices through out-of-band channels such as Xbox Live matchmaking. However, they represent a device's network address information at a particular time, and they can change over time. To avoid unnecessary connectivity problems, you should listen for XboxLiveDeviceAddress.SnapshotChanged events on the local device address to know when its snapshot contents have been updated, and refresh the serialized snapshot anywhere you've transmitted or cached it, so that remote devices always have the latest information.

Important

This API is not available to all apps. Unless your developer account is specially provisioned by Microsoft, calls to these APIs will fail at runtime.

// Register
event_token SnapshotChanged(TypedEventHandler<XboxLiveDeviceAddress, IInspectable const&> const& handler) const;

// Revoke with event_token
void SnapshotChanged(event_token const* cookie) const;

// Revoke with event_revoker
XboxLiveDeviceAddress::SnapshotChanged_revoker SnapshotChanged(auto_revoke_t, TypedEventHandler<XboxLiveDeviceAddress, IInspectable const&> const& handler) const;
public event TypedEventHandler<XboxLiveDeviceAddress,object> SnapshotChanged;
function onSnapshotChanged(eventArgs) { /* Your code */ }
xboxLiveDeviceAddress.addEventListener("snapshotchanged", onSnapshotChanged);
xboxLiveDeviceAddress.removeEventListener("snapshotchanged", onSnapshotChanged);
- or -
xboxLiveDeviceAddress.onsnapshotchanged = onSnapshotChanged;
Public Custom Event SnapshotChanged As TypedEventHandler(Of XboxLiveDeviceAddress, Object) 

Event Type

Applies to