IPGlobalProperties.GetIPv4GlobalStatistics メソッドとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > IPGlobalProperties.GetIPv4GlobalStatistics メソッドの意味・解説 

IPGlobalProperties.GetIPv4GlobalStatistics メソッド

メモ : このメソッドは、.NET Framework version 2.0新しく追加されたものです。

ローカル コンピュータインターネット プロトコル Version 4 (IPv4) 統計データ提供します

名前空間: System.Net.NetworkInformation
アセンブリ: System (system.dll 内)
構文構文

Public MustOverride Function
 GetIPv4GlobalStatistics As IPGlobalStatistics
Dim instance As IPGlobalProperties
Dim returnValue As IPGlobalStatistics

returnValue = instance.GetIPv4GlobalStatistics
public abstract IPGlobalStatistics GetIPv4GlobalStatistics ()
public:
virtual IPGlobalStatistics^ GetIPv4GlobalStatistics () abstract
public abstract IPGlobalStatistics GetIPv4GlobalStatistics ()
public abstract function GetIPv4GlobalStatistics
 () : IPGlobalStatistics

戻り値
ローカル コンピュータIPv4 トラフィック統計情報提供する IPGlobalStatistics オブジェクト

例外例外
例外種類条件

NetworkInformationException

Win32 関数 GetIpStatistics呼び出し失敗しました

解説解説
使用例使用例

ローカル コンピュータIP 統計情報表示するコード例次に示します

public static void ShowIPStatistics(NetworkInterfaceComponent
 version)
{
    IPGlobalProperties properties = IPGlobalProperties.GetIPGlobalProperties();
    IPGlobalStatistics ipstat = null;
    switch (version)
    {
        case NetworkInterfaceComponent.IPv4:
             ipstat = properties.GetIPv4GlobalStatistics();
           Console.WriteLine("{0}IPv4 Statistics ",Environment.NewLine);
            break;
        case NetworkInterfaceComponent.IPv6:
            ipstat = properties.GetIPv4GlobalStatistics();
            Console.WriteLine("{0}IPv6 Statistics ",Environment.NewLine);
            break;
        default:
            throw new ArgumentException("version");
            break;
    }
    Console.WriteLine("  Forwarding enabled ...................... : {0}",
 
        ipstat.ForwardingEnabled);
    Console.WriteLine("  Interfaces .............................. : {0}",
 
        ipstat.NumberOfInterfaces);
    Console.WriteLine("  IP addresses ............................ : {0}",
 
        ipstat.NumberOfIPAddresses);
    Console.WriteLine("  Routes .................................. : {0}",
 
        ipstat.NumberOfRoutes);
    Console.WriteLine("  Default TTL ............................. : {0}",
 
        ipstat.DefaultTtl);
    Console.WriteLine("");    
    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);
    Console.WriteLine("      Header Errors ....................... : {0}",
 
        ipstat.ReceivedPacketsWithHeadersErrors);
    Console.WriteLine("      Address Errors ...................... : {0}",
 
        ipstat.ReceivedPacketsWithAddressErrors);
    Console.WriteLine("      Unknown Protocol Errors ............. : {0}",
 
        ipstat.ReceivedPacketsWithUnknownProtocol);
    Console.WriteLine("");    
    Console.WriteLine("  Outbound Packet Data:");
    Console.WriteLine("      Requested ........................... : {0}",
 
         ipstat.OutputPacketRequests);
    Console.WriteLine("      Discarded ........................... : {0}",
 
        ipstat.OutputPacketsDiscarded);
    Console.WriteLine("      No Routing Discards ................. : {0}",
 
        ipstat.OutputPacketsWithNoRoute);
    Console.WriteLine("      Routing Entry Discards .............. : {0}",
 
        ipstat.OutputPacketRoutingDiscards);
    Console.WriteLine("");    
    Console.WriteLine("  Reassembly Data:");
    Console.WriteLine("      Reassembly Timeout .................. : {0}",
 
        ipstat.PacketReassemblyTimeout);
    Console.WriteLine("      Reassemblies Required ............... : {0}",
 
        ipstat.PacketReassembliesRequired);
    Console.WriteLine("      Packets Reassembled ................. : {0}",
 
        ipstat.PacketsReassembled);
    Console.WriteLine("      Packets Fragmented .................. : {0}",
 
        ipstat.PacketsFragmented);
    Console.WriteLine("      Fragment Failures ................... : {0}",
 
        ipstat.PacketFragmentFailures);
    Console.WriteLine("");
}
.NET Framework のセキュリティ.NET Frameworkセキュリティ
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
IPGlobalProperties クラス
IPGlobalProperties メンバ
System.Net.NetworkInformation 名前空間


このページでは「.NET Framework クラス ライブラリ リファレンス」からIPGlobalProperties.GetIPv4GlobalStatistics メソッドを検索した結果を表示しています。
Weblioに収録されているすべての辞書からIPGlobalProperties.GetIPv4GlobalStatistics メソッドを検索する場合は、下記のリンクをクリックしてください。
 全ての辞書からIPGlobalProperties.GetIPv4GlobalStatistics メソッド を検索

英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

IPGlobalProperties.GetIPv4GlobalStatistics メソッドのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



IPGlobalProperties.GetIPv4GlobalStatistics メソッドのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.

©2025 GRAS Group, Inc.RSS