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

接続を開いておく必要がある場合は true。それ以外の場合は false。

HTTP クライアントおよびサーバーが短期間の間に複数回データを交換する場合は、永続的な接続を使用すると、メッセージごとに TCP 接続を開いて閉じるために必要なオーバーヘッドがなくなるため、通信速度が向上します。HTTP/1.1 を使用しているクライアントの場合、このプロパティの既定値は true です。

public static void ShowRequestProperties2 (HttpListenerRequest request) { Console.WriteLine("KeepAlive: {0}", request.KeepAlive); Console.WriteLine("Local end point: {0}", request.LocalEndPoint.ToString()); Console.WriteLine("Remote end point: {0}", request.RemoteEndPoint.ToString()); Console.WriteLine("Is local? {0}", request.IsLocal); Console.WriteLine("HTTP method: {0}", request.HttpMethod); Console.WriteLine("Protocol version: {0}", request.ProtocolVersion); Console.WriteLine("Is authenticated: {0}", request.IsAuthenticated); Console.WriteLine("Is secure: {0}", request.IsSecureConnection); }

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


Weblioに収録されているすべての辞書からHttpListenerRequest.KeepAlive プロパティを検索する場合は、下記のリンクをクリックしてください。

- HttpListenerRequest.KeepAlive プロパティのページへのリンク