XboxLiveDeviceAddress Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Represents the network location of a console or other authenticated device.
Objects of this class represent an opaque collection of connectivity information about a device (in particular, a list of IP addresses). You pass an XboxLiveDeviceAddress to one of the XboxLiveEndpointPairTemplate class's CreateEndpointPairAsync or CreateEndpointPairForPortsAsync methods in order to instantiate an XboxLiveEndpointPair between the local device and the device at the given XboxLiveDeviceAddress.
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.
public ref class XboxLiveDeviceAddress sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Networking.XboxLive.XboxLiveSecureSocketsContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class XboxLiveDeviceAddress final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Networking.XboxLive.XboxLiveSecureSocketsContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class XboxLiveDeviceAddress
Public NotInheritable Class XboxLiveDeviceAddress
- Inheritance
- Attributes
Windows requirements
Device family |
Xbox One System Apps Extensions for the UWP (introduced in 10.0.0.1)
Xbox Live Extension SDK (introduced in 10.0.10240.0) Xbox One Extensions for the UWP (introduced in 10.0.10240.0) Windows Desktop Extension SDK (introduced in 10.0.16299.0) |
API contract |
Windows.Networking.XboxLive.XboxLiveSecureSocketsContract (introduced in v1.0)
|
Properties
IsLocal |
Gets a Boolean value indicating whether this XboxLiveDeviceAddress represents the local device. 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. |
IsValid |
Gets a Boolean value indicating whether this XboxLiveDeviceAddress is valid. 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. |
MaxSnapshotBytesSize |
Gets a value that specifies the maximum number of Bytes required for the array of Bytes passed to XboxLiveDeviceAddress.GetSnapshotAsBytes. 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. |
NetworkAccessKind |
Gets a value that describes the level of peer-to-peer network access observed for XboxLiveEndpointPair communication involving this XboxLiveDeviceAddress. The indicated access is applicable only to communication established through the Xbox Live Multiplayer Networking API infrastructure. If you establish your own insecure communication, or implement your own NAT traversal, then you might find that that code encounters a different access kind. 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. |
Methods
Compare(XboxLiveDeviceAddress) |
Compares another XboxLiveDeviceAddress object to the current object, to see whether they represent the same device. 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. |
CreateFromSnapshotBase64(String) |
Creates an XboxLiveDeviceAddress object from a snapshot stored in Base64 encoding. Use this method to create an XboxLiveDeviceAddress from the Base64-encoded snapshot returned from an earlier call to XboxLiveDeviceAddress.GetSnapshotAsBase64. 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. |
CreateFromSnapshotBuffer(IBuffer) |
Creates an XboxLiveDeviceAddress object from a snapshot stored in a buffer. Use this method to create an XboxLiveDeviceAddress from the snapshot buffer returned from an earlier call to XboxLiveDeviceAddress.GetSnapshotAsBuffer. 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. |
CreateFromSnapshotBytes(Byte[]) |
Creates an XboxLiveDeviceAddress from a snapshot stored as an array of bytes. Use this method to create an XboxLiveDeviceAddress object from a saved snapshot retrieved with the XboxLiveDeviceAddress.GetSnapshotAsBytes method. 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. |
GetLocal() |
Creates an XboxLiveDeviceAddress for the local device. 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. |
GetSnapshotAsBase64() |
Gets a snapshot of the current XboxLiveDeviceAddress as a Base64-encoded string. You can save this snapshot to use later as the base64 parameter in a call to XboxLiveDeviceAddress.CreateFromSnapshotBase64. 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. |
GetSnapshotAsBuffer() |
Gets a snapshot of the current XboxLiveDeviceAddress and returns it as an object that implements IBuffer. You can use this method to save a snapshot for later use with the XboxLiveDeviceAddress.CreateFromSnapshotBuffer method. 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. |
GetSnapshotAsBytes(Byte[], UInt32) |
Saves an XboxLiveDeviceAddress to an array of bytes. You can use this method to save a snapshot for use with the XboxLiveDeviceAddress.CreateFromSnapshotBytes method. 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. |
Events
SnapshotChanged |
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. |