Share via


IContextManager.GetContext メソッド

定義

コンテキストを取得します。

public:
 System::Collections::Generic::IDictionary<System::String ^, System::String ^> ^ GetContext();
public System.Collections.Generic.IDictionary<string,string> GetContext ();
abstract member GetContext : unit -> System.Collections.Generic.IDictionary<string, string>
Public Function GetContext () As IDictionary(Of String, String)

戻り値

名前空間およびコンテキスト名が含まれたキーと値のペアの IDictionary<TKey,TValue>

次のコードは、クライアント上の型指定のあるプロキシ インスタンスからコンテキストを取得する方法を示しています。

IDictionary<string, string> context;  
CalculatorProxy proxy;  
IContextManager cm = proxy.InnerChannel.GetProperty<IContextManager>();  
if (cm != null)  
    context = cm.GetContext();  

適用対象