ConnectionProfile.GetConnectivityIntervalsAsync(DateTime, DateTime, NetworkUsageStates) ConnectionProfile.GetConnectivityIntervalsAsync(DateTime, DateTime, NetworkUsageStates) ConnectionProfile.GetConnectivityIntervalsAsync(DateTime, DateTime, NetworkUsageStates) ConnectionProfile.GetConnectivityIntervalsAsync(DateTime, DateTime, NetworkUsageStates) ConnectionProfile.GetConnectivityIntervalsAsync(DateTime, DateTime, NetworkUsageStates) Method

Definition

Gets a list of ConnectivityInterval objects, which indicate the timestamp for when the network connection began, and a time-span for the duration of that connection.

public : IAsyncOperation<IVectorView<ConnectivityInterval>> GetConnectivityIntervalsAsync(DateTime startTime, DateTime endTime, NetworkUsageStates states)
IAsyncOperation<IVectorView<ConnectivityInterval>> GetConnectivityIntervalsAsync(DateTime startTime, DateTime endTime, NetworkUsageStates states) const;
public IAsyncOperation<IReadOnlyList<ConnectivityInterval>> GetConnectivityIntervalsAsync(DateTimeOffset startTime, DateTimeOffset endTime, NetworkUsageStates states)
Public Function GetConnectivityIntervalsAsync(startTime As DateTimeOffset, endTime As DateTimeOffset, states As NetworkUsageStates) As IAsyncOperation<IReadOnlyList<ConnectivityInterval>>(Of IVectorView)
Windows.Networking.Connectivity.ConnectionProfile.getConnectivityIntervalsAsync(startTime, endTime, states).done( /* Your success and error handlers */ );

Parameters

startTime
DateTimeOffset DateTimeOffset DateTimeOffset

The start time over which to retrieve data. Can be no more than 60 days prior to the current time.

endTime
DateTimeOffset DateTimeOffset DateTimeOffset

The end time over which to retrieve data.

states
NetworkUsageStates NetworkUsageStates NetworkUsageStates

The state of the connection profile for which usage data should be returned.

Returns

IAsyncOperation<IReadOnlyList<ConnectivityInterval>> IAsyncOperation<IReadOnlyList<ConnectivityInterval>> IAsyncOperation<IReadOnlyList<ConnectivityInterval>>

When the method completes, it returns a list of ConnectivityInterval objects, which indicate the start time and duration for the current or prior connections.

Remarks

For an example of how these methods are used, see How to retrieve connection usage data for a specific period of time