Share via


IWMSPublishingPointPeakCounters Object (C#)

You can use the IWMSPublishingPointPeakCounters object to retrieve properties that contain information about peak events that occur during publishing point operation.

The IWMSPublishingPointPeakCounters object exposes the following properties and methods.

Property

Description

AllCounters

Retrieves an array that contains all of the counters supported by the object.

ConnectedPlayers

Retrieves the maximum number of players that have been connected to the publishing point simultaneously.

CountersStartTime

Retrieves the date and time at which the publishing point started monitoring the peak counters.

OutgoingDistributionAllocatedBandwidth

Retrieves the maximum bandwidth that has been allocated to a distribution connection.

OutgoingDistributionConnections

Retrieves the maximum number of permitted distribution connections.

PlayerAllocatedBandwidth

Retrieves the maximum bandwidth that has been allocated to player connections.

StreamingPlayers

Retrieves the maximum number of players that have streamed content simultaneously from the publishing point.

StreamingHTTPPlayers

Retrieves the maximum number of players that have streamed content simultaneously by using the HTTP protocol from the publishing point.

StreamingRTSPPlayers

Retrieves the maximum number of players that have streamed content simultaneously by using the RTSP protocol from the publishing point.

StreamingUDPPlayers

Retrieves the maximum number of players that have streamed content simultaneously by using the User Datagram Protocol (UDP) from the publishing point.

Method

Description

Reset

Resets the counters to the current values.

Example

The following example illustrates how to retrieve an IWMSPublishingPointPeakCounters object.

using Microsoft.WindowsMediaServices.Interop;
using System.Runtime.InteropServices;

// Declare variables.
WMSServer                            Server;
IWMSPublishingPoints                 PubPoints;
IWMSPublishingPoint                  PubPoint;
IWMSPublishingPointPeakCounters      PeakCounters;

try {
    // Create a new WMSServer object.
    Server = new WMSServerClass();

    // Retrieve the IWMSPublishingPoints object.
    PubPoints = Server.PublishingPoints;

    // Retrieve information about each publishing point.
    for (int i = 0; i < PubPoints.Count; i++)
    {
        PubPoint = PubPoints[i];

        // Retrieve a pointer to a list of peak statistics
        // for the publishing point.
        PeakCounters = PubPoint.PeakCounters;
    }
}
catch (COMException comExc) {
    // TODO: Handle COM exceptions.
}
catch (Exception e) {
    // TODO: Handle exceptions.
}