Class Activity

Represents the base class for activity.

Inheritance
System.Object
Activity
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Mediachase.Commerce.WorkflowCompatibility
Assembly: Mediachase.Commerce.dll
Version: 10.8.0
Syntax
public abstract class Activity

Constructors

Activity()

Declaration
protected Activity()

Properties

Context

The context of activity flow execution which contains the activity as a step.

Declaration
protected ActivityFlowContext Context { get; }
Property Value
Type Description
ActivityFlowContext

Methods

AddHandler(DependencyProperty, EventHandler)

Adds a handler for an event declared as a dependency property.

Declaration
[Obsolete("This method is no longer used. Please use the method without DependencyProperty argument. Will remain at least until October 2016.")]
protected void AddHandler(DependencyProperty dependencyEvent, EventHandler handler)
Parameters
Type Name Description
DependencyProperty dependencyEvent

The dependency property defining the event.

System.EventHandler handler

Handler for the event.

Execute()

Executes the activity.

Declaration
public bool Execute()
Returns
Type Description
System.Boolean

Flag to indicate whether the activity is completed or not.

Execute(ActivityExecutionContext)

Executes the activity.

Declaration
protected abstract ActivityExecutionStatus Execute(ActivityExecutionContext executionContext)
Parameters
Type Name Description
ActivityExecutionContext executionContext

the ActivityExecutionContext object.

Returns
Type Description
ActivityExecutionStatus

status of the activity execution.

GetValue(DependencyProperty)

Gets value of a property declared as dependency property.

Declaration
[Obsolete("This method is no longer used. Please use a normal getter to get value of property. Will remain at least until October 2016.")]
protected object GetValue(DependencyProperty property)
Parameters
Type Name Description
DependencyProperty property

The dependency property.

Returns
Type Description
System.Object

Value of property.

InitializeComponent()

Declaration
[Obsolete("This method is no longer used since the new ActivityFlow engine does not need this. Will remain at least until October 2016.")]
protected void InitializeComponent()

RaiseEvent(DependencyProperty, Activity, EventArgs)

Raises an event

Declaration
[Obsolete("This method is no longer used. Please use the method without Activity and DependencyProperty arguments. Will remain at least until October 2016.")]
protected void RaiseEvent(DependencyProperty eventDepedency, Activity activity, EventArgs args)
Parameters
Type Name Description
DependencyProperty eventDepedency

The dependency property.

Activity activity

The activity.

System.EventArgs args

The event arguments.

RaiseEvent(DependencyProperty, EventArgs)

Raises an event of the activity.

Declaration
[Obsolete("This method is no longer used. Please use the method without DependencyProperty arguments. Will remain at least until October 2016.")]
protected void RaiseEvent(DependencyProperty dependencyEvent, EventArgs args)
Parameters
Type Name Description
DependencyProperty dependencyEvent

The event declared as a dependency property.

System.EventArgs args

The event arguments.

RaiseEvent(String, Activity, EventArgs)

Raises an event

Declaration
[Obsolete("This method is no longer used. Please use the method without Activity argument. Will remain at least until October 2016.")]
protected void RaiseEvent(string eventName, Activity activity, EventArgs args)
Parameters
Type Name Description
System.String eventName

Name of the event.

Activity activity

The activity.

System.EventArgs args

The event arguments.

RaiseEvent(String, EventArgs)

Raises an event of the activity.

Declaration
protected void RaiseEvent(string eventName, EventArgs args)
Parameters
Type Name Description
System.String eventName

Name of the event.

System.EventArgs args

The event arguments.

RemoveHandler(DependencyProperty, EventHandler)

Removes a handler of an event declared as a dependency property.

Declaration
[Obsolete("This method is no longer used. Please use the method without DependencyProperty arguments. Will remain at least until October 2016.")]
protected void RemoveHandler(DependencyProperty dependencyEvent, EventHandler handler)
Parameters
Type Name Description
DependencyProperty dependencyEvent

The dependency property defining the event.

System.EventHandler handler

Handler of the event.

SetValue(DependencyProperty, Object)

Sets value of a property declared as dependecy property.

Declaration
[Obsolete("This method is no longer used. Please use a normal setter to set value of property. Will remain at least until October 2016.")]
protected void SetValue(DependencyProperty property, object value)
Parameters
Type Name Description
DependencyProperty property

The dependecy property.

System.Object value

Value of property.

ValidateProperties(ValidationErrorCollection)

Validate the properties of activity.

Declaration
protected virtual bool ValidateProperties(ValidationErrorCollection validationErrors)
Parameters
Type Name Description
ValidationErrorCollection validationErrors

The validation errors.

Returns
Type Description
System.Boolean