IPGlobalStatistics.ReceivedPacketsForwarded プロパティ
アセンブリ: System (system.dll 内)

転送されたパケットの合計数を示す Int64 値。

ローカル コンピュータがルーターではない場合、このプロパティによって返される値には、ローカル コンピュータ経由で正常にソース ルーティングされたパケットが含まれます。ソース ルーティングは、パケットの送信元で送信先アドレスへの経路を指定できる IP オプションです。

受信した IP パケットの統計情報を表示するコード例を次に示します。
Public Shared Sub ShowInboundIPStatistics() Dim properties As IPGlobalProperties = IPGlobalProperties.GetIPGlobalProperties() Dim ipstat As IPGlobalStatistics = properties.GetIPv4GlobalStatistics() Console.WriteLine(" Inbound Packet Data:") Console.WriteLine(" Received ............................ : {0}", ipstat.ReceivedPackets) Console.WriteLine(" Forwarded ........................... : {0}", ipstat.ReceivedPacketsForwarded) Console.WriteLine(" Delivered ........................... : {0}", ipstat.ReceivedPacketsDelivered) Console.WriteLine(" Discarded ........................... : {0}", ipstat.ReceivedPacketsDiscarded) End Sub 'ShowInboundIPStatistics
public static void ShowInboundIPStatistics() { IPGlobalProperties properties = IPGlobalProperties.GetIPGlobalProperties(); IPGlobalStatistics ipstat = properties.GetIPv4GlobalStatistics(); Console.WriteLine(" Inbound Packet Data:"); Console.WriteLine(" Received ............................ : {0}", ipstat.ReceivedPackets); Console.WriteLine(" Forwarded ........................... : {0}", ipstat.ReceivedPacketsForwarded); Console.WriteLine(" Delivered ........................... : {0}", ipstat.ReceivedPacketsDelivered); Console.WriteLine(" Discarded ........................... : {0}", ipstat.ReceivedPacketsDiscarded); }

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


- IPGlobalStatistics.ReceivedPacketsForwarded プロパティのページへのリンク