GlobalProxySelection.Select プロパティとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > GlobalProxySelection.Select プロパティの意味・解説 

GlobalProxySelection.Select プロパティ

グローバル HTTP プロキシ取得または設定します

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

Public Shared Property Select
 As IWebProxy
Dim value As IWebProxy

value = GlobalProxySelection.Select

GlobalProxySelection.Select = value
public static IWebProxy Select { get;
 set; }
public:
static property IWebProxy^ Select {
    IWebProxy^ get ();
    void set (IWebProxy^ value);
}
/** @property */
public static IWebProxy get_Select ()

/** @property */
public static void set_Select
 (IWebProxy value)

プロパティ
HttpWebRequest.GetResponse へのすべての呼び出し使用する IWebProxy。

例外例外
例外種類条件

ArgumentNullException

設定操作として指定した値が null 参照 (Visual Basic では Nothing) です。

SecurityException

要求され操作実行するためのアクセス許可呼び出し元にありません。

解説解説
使用例使用例

Select プロパティを空のプロキシ設定するコード例次に示します

using System;
using System.Net;
using System.IO;
namespace Examples.Http
{
    public class TestGlobalProxySelection
    {
        public static void
 Main()
        {
            // Create a request for the Web page at www.contoso.com.
            WebRequest request = WebRequest.Create("http://www.contoso.com");
            // This application doesn't want the proxy to be used so
 it sets 
            // the global proxy to an empty proxy.
            IWebProxy myProxy = GlobalProxySelection.GetEmptyWebProxy();
            GlobalProxySelection.Select = myProxy;
            // Get the response.
            WebResponse response = request.GetResponse();
            // Display the response to the console.
            Stream stream = response.GetResponseStream();
            StreamReader reader = new StreamReader(stream);
            Console.WriteLine(reader.ReadToEnd());
            // Clean up.
            reader.Close();
            stream.Close();
            response.Close();
        }
    }
}
#using <System.dll>

using namespace System;
using namespace System::Net;
using namespace System::IO;
int main()
{
   
   // Create a request for the Web page at www.contoso.com.
   WebRequest^ request = WebRequest::Create( L"http://www.contoso.com"
 );
   
   // This application doesn't want they proxy to be used so it sets
   // the global proxy to an empy proxy.
   IWebProxy^ myProxy = GlobalProxySelection::GetEmptyWebProxy();
   
   // Get the response.
   WebResponse^ response = request->GetResponse();
   
   // Display the response to the console.
   Stream^ stream = response->GetResponseStream();
   StreamReader^ reader = gcnew StreamReader( stream );
   Console::WriteLine( reader->ReadToEnd() );
   
   // Clean up.
   reader->Close();
   stream->Close();
   response->Close();
   return 0;
}
package Examples.Http;

import System.*;
import System.Net.*;
import System.IO.*;

public class TestGlobalProxySelection
{
    public static void main(String[]
 args)
    {
        // Create a request for the Web page at www.contoso.com.
        WebRequest request = WebRequest.Create("http://www.contoso.com");
        // This application doesn't want they proxy to be used so it
 sets 
        // the global proxy to an empy proxy.
        IWebProxy myProxy = GlobalProxySelection.GetEmptyWebProxy();
        GlobalProxySelection.set_Select(myProxy);
        // Get the response.
        WebResponse response = request.GetResponse();
        // Display the response to the console.
        Stream stream = response.GetResponseStream();
        StreamReader reader = new StreamReader(stream);
        Console.WriteLine(reader.ReadToEnd());
        // Clean up.
        reader.Close();
        stream.Close();
        response.Close();
    } //main
} //TestGlobalProxySelection
.NET Framework のセキュリティ.NET Frameworkセキュリティ
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
GlobalProxySelection クラス
GlobalProxySelection メンバ
System.Net 名前空間


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

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

辞書ショートカット

すべての辞書の索引

「GlobalProxySelection.Select プロパティ」の関連用語

GlobalProxySelection.Select プロパティのお隣キーワード
検索ランキング

   

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



GlobalProxySelection.Select プロパティのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

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

©2025 GRAS Group, Inc.RSS