Share via


ExtensionContextExtensions Class

Inheritance Hierarchy

System.Object
  Microsoft.VisualStudio.Modeling.Diagrams.ExtensionEnablement.ExtensionContextExtensions

Namespace:  Microsoft.VisualStudio.Modeling.Diagrams.ExtensionEnablement
Assembly:  Microsoft.VisualStudio.Modeling.Sdk.Diagrams.12.0 (in Microsoft.VisualStudio.Modeling.Sdk.Diagrams.12.0.dll)

Syntax

'Declaration
<ExtensionAttribute> _
Public NotInheritable Class ExtensionContextExtensions
public static class ExtensionContextExtensions
[ExtensionAttribute]
public ref class ExtensionContextExtensions abstract sealed
[<AbstractClass>]
[<Sealed>]
type ExtensionContextExtensions =  class end
public final class ExtensionContextExtensions

The ExtensionContextExtensions type exposes the following members.

Methods

  Name Description
Public methodStatic member AtLeastOneSelected<T>(IVsSelectionContext) Helper returning true if the selection contains at least an element of type T
Public methodStatic member AtLeastOneSelected<T1, T2>(IVsSelectionContext) Helper returning true if the selection contains at least an element of type T1 or T2.
Public methodStatic member GetCurrentDocumentSelection<T> Get the subset of the current document selection which is of type T
Public methodStatic member GetCurrentSelection<T> Get the subset of the current selection which is of type T
Public methodStatic member IsAnyDocumentSelectionUndeletable Returns whether any of the shape items in the selection list cannot be deleted. This implementation checks for Compartment and MoveableHostShape shapes.
Public methodStatic member IsSingleDocumentSelection Returns whether or not there is only one selected item on the active document.
Public methodStatic member IsSingleSelection Returns whether or not there is only one selected item on the active window. This could be a document or tool window.

Top

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.VisualStudio.Modeling.Diagrams.ExtensionEnablement Namespace