TaskProvider Class

A feature provider that you can add to a class to automatically add tasks to the active tool.

Inheritance Hierarchy

System.Object
  Microsoft.Windows.Design.Features.FeatureProvider
    Microsoft.Windows.Design.Interaction.TaskProvider
      Microsoft.Windows.Design.Interaction.PrimarySelectionTaskProvider

Namespace:  Microsoft.Windows.Design.Interaction
Assembly:  Microsoft.Windows.Design.Interaction (in Microsoft.Windows.Design.Interaction.dll)

Syntax

'Declaration
Public MustInherit Class TaskProvider _
    Inherits FeatureProvider
public abstract class TaskProvider : FeatureProvider
public ref class TaskProvider abstract : public FeatureProvider
[<AbstractClass>]
type TaskProvider =  
    class
        inherit FeatureProvider
    end
public abstract class TaskProvider extends FeatureProvider

The TaskProvider type exposes the following members.

Constructors

  Name Description
Protected method TaskProvider Initializes a new instance of the TaskProvider class.

Top

Properties

  Name Description
Protected property Context Gets the editing context that activated this task provider.
Public property Tasks Gets a collection of tasks this task provider offers.

Top

Methods

  Name Description
Protected method Activate Called when a task provider's tasks are about to be requested for the first time.
Protected method Deactivate Called when a task provider is about to be discarded by the designer.
Public method Equals Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public method GetHashCode Serves as a hash function for a particular type. (Inherited from Object.)
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Public method IsToolSupported Returns a value indicating whether this task provider supports the specified tool.
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method ToString Returns a string that represents the current object. (Inherited from Object.)

Top

Remarks

Tasks are added to the tool according to a task provider's policy. You can implement this abstract class to provide Task objects to a particular tool or tools. Tasks can be added to the Tasks property. Implement the IsToolSupported method to indicate if a particular tool is supported by your implementation of TaskProvider.

Thread Safety

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

See Also

Reference

Microsoft.Windows.Design.Interaction Namespace

Other Resources

Understanding WPF Designer Extensibility