CorrelationProperty Class

 
Note: This API is now obsolete.

Represents a name and value pair used to correlate messages to specific receiving activities.

Namespace:   System.Workflow.Runtime
Assembly:  System.Workflow.Runtime (in System.Workflow.Runtime.dll)

System.Object
  System.Workflow.Runtime.CorrelationProperty

[SerializableAttribute]
[ObsoleteAttribute("The System.Workflow.* types are deprecated.  Instead, please use the new types from System.Activities.*")]
public class CorrelationProperty

NameDescription
System_CAPS_pubmethodCorrelationProperty(String, Object)

Initializes a new instance of the CorrelationProperty class.

NameDescription
System_CAPS_pubpropertyName

Gets the name of the property used in the correlation set.

System_CAPS_pubpropertyValue

Gets the value of the correlation set property.

NameDescription
System_CAPS_pubmethodEquals(Object)

Determines whether the specified object is equal to the current object.(Inherited from Object.)

System_CAPS_protmethodFinalize()

Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.)

System_CAPS_pubmethodGetHashCode()

Serves as the default hash function. (Inherited from Object.)

System_CAPS_pubmethodGetType()

Gets the Type of the current instance.(Inherited from Object.)

System_CAPS_protmethodMemberwiseClone()

Creates a shallow copy of the current Object.(Inherited from Object.)

System_CAPS_pubmethodToString()

Returns a string that represents the current object.(Inherited from Object.)

System_CAPS_noteNote

This material discusses types and namespaces that are obsolete. For more information, see Deprecated Types in Windows Workflow Foundation 4.5.

CorrelationProperty classes are defined as ActivityBind properties of Workflow Connection Service activities. By default, these properties are bound to variables declared at the root workflow activity. For dynamic activities such as ReplicatorActivity and ConditionedActivityGroup each of its children cannot share a universal CorrelationProperty object. Consider the scenario where each task inside a ReplicatorActivity has to manage its own conversation. The child activities inside the ReplicatorActivity requires a CorrelationProperty instance unique per execution context, or per task. In order to accomplish this, you have to define a custom activity that has a CorrelationProperty instance property and the Workflow Connection Services activities have to bind to this property.

The following example demonstrates creating a correlation property object, and accessing the Name and Value properties.

// Create a new Correlation Property object
CorrelationProperty correlationProperty = new CorrelationProperty("taskName", "reportBalance");
// Read the property name
String taskName = correlationProperty.Name;
// Read the property value
Object taskValue = correlationProperty.Value;

.NET Framework
Available since 3.0

Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show: