Selection Selection Selection Selection Class

Definition

Defines a selection of objects that are published as a ContextItem in the EditingContext.

public ref class Selection : System::Activities::Presentation::ContextItem
public class Selection : System.Activities.Presentation.ContextItem
type Selection = class
    inherit ContextItem
Public Class Selection
Inherits ContextItem
Inheritance

Remarks

Selections consist of zero or more objects. The first object in a selection is defined as the primary selection, which is used when one object in a group must be used as a key. Each object is stored as a ModelItem.

Constructors

Selection() Selection() Selection() Selection()

Creates an empty Selection object.

Selection(IEnumerable) Selection(IEnumerable) Selection(IEnumerable) Selection(IEnumerable)

Creates a Selection object with the specified objects selected.

Selection(IEnumerable, Predicate<ModelItem>) Selection(IEnumerable, Predicate<ModelItem>) Selection(IEnumerable, Predicate<ModelItem>) Selection(IEnumerable, Predicate<ModelItem>)

Creates a Selection object with the specified objects selected.

Selection(IEnumerable<ModelItem>) Selection(IEnumerable<ModelItem>) Selection(IEnumerable<ModelItem>) Selection(IEnumerable<ModelItem>)

Creates a Selection object with the specified objects selected.

Selection(IEnumerable<ModelItem>, Predicate<ModelItem>) Selection(IEnumerable<ModelItem>, Predicate<ModelItem>) Selection(IEnumerable<ModelItem>, Predicate<ModelItem>) Selection(IEnumerable<ModelItem>, Predicate<ModelItem>)

Creates a Selection object with the specified objects selected.

Selection(ModelItem[]) Selection(ModelItem[]) Selection(ModelItem[]) Selection(ModelItem[])

Creates a Selection object with the specified objects selected.

Properties

ItemType ItemType ItemType ItemType

Returns the item type for this editing context item.

PrimarySelection PrimarySelection PrimarySelection PrimarySelection

Returns the primary selection.

SelectedObjects SelectedObjects SelectedObjects SelectedObjects

The enumeration of selected objects.

SelectionCount SelectionCount SelectionCount SelectionCount

The number of objects that are currently selected in this selection.

Methods

Equals(Object) Equals(Object) Equals(Object) Equals(Object)

Determines whether the specified object is equal to the current object.

(Inherited from Object)
GetHashCode() GetHashCode() GetHashCode() GetHashCode()

Serves as the default hash function.

(Inherited from Object)
GetType() GetType() GetType() GetType()

Gets the Type of the current instance.

(Inherited from Object)
MemberwiseClone() MemberwiseClone() MemberwiseClone() MemberwiseClone()

Creates a shallow copy of the current Object.

(Inherited from Object)
OnItemChanged(EditingContext, ContextItem) OnItemChanged(EditingContext, ContextItem) OnItemChanged(EditingContext, ContextItem) OnItemChanged(EditingContext, ContextItem)

Represents a method that is called on the context item before it is stored in the context item manager. The previous item in the context item manager is passed as a parameter.

(Inherited from ContextItem)
Select(EditingContext, ModelItem) Select(EditingContext, ModelItem) Select(EditingContext, ModelItem) Select(EditingContext, ModelItem)

A selection helper method that takes the existing selection in the context and selects an item into it. If the item is already in the selection, the selection is preserved and the item is promoted to the primary selection.

SelectOnly(EditingContext, ModelItem) SelectOnly(EditingContext, ModelItem) SelectOnly(EditingContext, ModelItem) SelectOnly(EditingContext, ModelItem)

A selection helper method that sets an item into the selection. Any existing items are deselected.

Subscribe(EditingContext, SubscribeContextCallback<Selection>) Subscribe(EditingContext, SubscribeContextCallback<Selection>) Subscribe(EditingContext, SubscribeContextCallback<Selection>) Subscribe(EditingContext, SubscribeContextCallback<Selection>)

A helper method that subscribes to selection change events.

Toggle(EditingContext, ModelItem) Toggle(EditingContext, ModelItem) Toggle(EditingContext, ModelItem) Toggle(EditingContext, ModelItem)

A selection helper method that takes the existing selection in the context and creates a new selection that contains the toggled state of the item. If the item is to be added to the selection, it is added as the primary selection.

ToString() ToString() ToString() ToString()

Returns a string that represents the current object.

(Inherited from Object)
Union(EditingContext, ModelItem) Union(EditingContext, ModelItem) Union(EditingContext, ModelItem) Union(EditingContext, ModelItem)

A selection helper method that takes the existing selection in the context and creates a new selection that contains the original selection and the specified item to add. If the specified item to add is already in the original selection, it is promoted to the primary selection.

Unsubscribe(EditingContext, SubscribeContextCallback<Selection>) Unsubscribe(EditingContext, SubscribeContextCallback<Selection>) Unsubscribe(EditingContext, SubscribeContextCallback<Selection>) Unsubscribe(EditingContext, SubscribeContextCallback<Selection>)

A helper method that removes a previously added selection change event.

Applies to