feyris-tan ef86554f9a Import
2025-05-12 22:09:16 +02:00

37 lines
752 B
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace SDL2Demo.Net
{
public class IpPerformanceInfo
{
public long TotalPackets;
public long PacketsSinceSecond;
public long PacketsPerSecond;
public long TotalBytes;
public long BytesSinceSecond;
public long BytesPerSecond;
public string SourceResolution;
public string DestinationResolution;
public void UpdatePerSeconds()
{
PacketsPerSecond = PacketsSinceSecond;
PacketsSinceSecond = 0;
BytesPerSecond = BytesSinceSecond;
BytesSinceSecond = 0;
}
public void CountPacket(int len)
{
TotalPackets++;
PacketsSinceSecond++;
TotalBytes += len;
BytesSinceSecond += len;
}
}
}