Jazyk

SendActivity.SetContext Metoda

Definice

Nastaví kontextové informace pro SendActivity aktivitu.

Přetížení

Name Description
SetContext(Activity, ChannelToken, Type, IDictionary<String,String>)

Statická metoda, která nastavuje kontextové informace pro SendActivity aktivitu, vzhledem k instanci aktivity, koncový bod používaný danou aktivitou, objekt, Type který představuje typ kontraktu, a samotné kontextové informace.

SetContext(Activity, String, String, Type, IDictionary<String,String>)

Statická metoda, která nastavuje kontextové informace pro SendActivity aktivitu, vzhledem k instanci aktivity, název koncového bodu používaného danou aktivitou, název aktivity vlastníka, objekt, Type který představuje typ kontraktu, a informace o kontextu samotné.

Poznámky

Kontextové informace slouží ke komunikaci mezi klientem a službou, která komunikuje, a zahrnují například identifikaci korelace.

SetContext(Activity, ChannelToken, Type, IDictionary<String,String>)

Statická metoda, která nastavuje kontextové informace pro SendActivity aktivitu, vzhledem k instanci aktivity, koncový bod používaný danou aktivitou, objekt, Type který představuje typ kontraktu, a samotné kontextové informace.

public:
 static void SetContext(System::Workflow::ComponentModel::Activity ^ activity, System::Workflow::Activities::ChannelToken ^ endpoint, Type ^ contractType, System::Collections::Generic::IDictionary<System::String ^, System::String ^> ^ context);
public static void SetContext(System.Workflow.ComponentModel.Activity activity, System.Workflow.Activities.ChannelToken endpoint, Type contractType, System.Collections.Generic.IDictionary<string,string> context);
static member SetContext : System.Workflow.ComponentModel.Activity * System.Workflow.Activities.ChannelToken * Type * System.Collections.Generic.IDictionary<string, string> -> unit
Public Shared Sub SetContext (activity As Activity, endpoint As ChannelToken, contractType As Type, context As IDictionary(Of String, String))

Parametry

activity
Activity

Instance aktivity, ke které chcete přidružit kontextové informace.

endpoint
ChannelToken

Koncový bod použitý pro korelaci se službou.

contractType
Type

Smlouva Type implementovaná službou.

context
IDictionary<String,String>

Kontextové informace, které chcete nastavit.

Příklady

Následující příklad ukazuje, jak použít metodu SetContext .

Poznámky

Kontextové informace slouží ke komunikaci mezi klientem a službou, se kterými komunikuje, a zahrnují například identifikaci korelace.

Platí pro

SetContext(Activity, String, String, Type, IDictionary<String,String>)

Statická metoda, která nastavuje kontextové informace pro SendActivity aktivitu, vzhledem k instanci aktivity, název koncového bodu používaného danou aktivitou, název aktivity vlastníka, objekt, Type který představuje typ kontraktu, a informace o kontextu samotné.

public:
 static void SetContext(System::Workflow::ComponentModel::Activity ^ activity, System::String ^ endpointName, System::String ^ ownerActivityName, Type ^ contractType, System::Collections::Generic::IDictionary<System::String ^, System::String ^> ^ context);
public static void SetContext(System.Workflow.ComponentModel.Activity activity, string endpointName, string ownerActivityName, Type contractType, System.Collections.Generic.IDictionary<string,string> context);
static member SetContext : System.Workflow.ComponentModel.Activity * string * string * Type * System.Collections.Generic.IDictionary<string, string> -> unit
Public Shared Sub SetContext (activity As Activity, endpointName As String, ownerActivityName As String, contractType As Type, context As IDictionary(Of String, String))

Parametry

activity
Activity

Instance aktivity, ke které chcete přidružit kontextové informace.

endpointName
String

Název koncového bodu, který se používá pro korelaci se službou.

ownerActivityName
String

Název vlastnící aktivity.

contractType
Type

Smlouva Type implementovaná službou.

context
IDictionary<String,String>

Kontextové informace, které chcete nastavit.

Platí pro