IContextManager.GetContext Metod

Definition

Hämtar kontexten.

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)

Returer

Nyckel IDictionary<TKey,TValue> /värde-par med namnområdet och namnet på kontexten.

Exempel

Följande kod visar hur kontexten kan hämtas från en typad proxyinstans på klienten.

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

Gäller för